/*****************************************************************************
*
* Filename         - $Workfile:   bag_manifest_totals_v1.sql  $
*
* Project Name     - TAGTRAK(Oracle Database)
*
* Design Spec
* Section          -
*
* Contents         - Live Schema View
*
* Language         - Oracle SQL*Plus script
*
* Classification   - Commercial In Confidence
*
*          (c) Ultra Electronics Limited, 2003
*
*****************************************************************************/
PROMPT Creating view bag_manifest_totals_v1 

CREATE OR REPLACE FORCE
VIEW bag_manifest_totals_v1 
(flight_id
,total_bags
,total_accompanied
,total_unaccompanied
) AS
SELECT flight_id
,NVL(bag_manifest_totals.bags_total(flight_id),0)
,NVL(bag_manifest_totals.bags_accompanied(flight_id),0)
,NVL(bag_manifest_totals.bags_unaccompanied(flight_id),0)
FROM flight_outbound_v1 
/
