From 7864d2d918a9c80d20ed94da4eb0a11a98c76da7 Mon Sep 17 00:00:00 2001 From: mullenm Date: Wed, 16 Jan 2008 14:46:43 +0000 Subject: [PATCH] Added Qmin and column comments to make it easier for other people. git-svn-id: http://locode01.ad.dom/svn/WEBMIP/trunk@3263 248e525c-4dfb-0310-94bc-949c084e9493 --- Schema/V_QUOTE_DETAILS.vw | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Schema/V_QUOTE_DETAILS.vw b/Schema/V_QUOTE_DETAILS.vw index da96c57..ab8d3a4 100644 --- a/Schema/V_QUOTE_DETAILS.vw +++ b/Schema/V_QUOTE_DETAILS.vw @@ -5,7 +5,7 @@ may be required. */ CREATE OR REPLACE VIEW V_QUOTE_DETAILS AS -SELECT "ENQUIRY_ID","QUOTE_ID","ENTY_CODE","MODULE_CODE","LEAD_TIME","ADDITIONAL_ITEMS","BAS_CODE","QMAX","INLET_ORIENTATION","OUTLET_ORIENTATION","TOTAL_COST","ROW_NUMBER" +SELECT * FROM (SELECT q.enqu_id AS enquiry_id ,t.qute_id AS quote_id ,MAX(t.enty_code) over(PARTITION BY qute_id) AS enty_code @@ -14,6 +14,7 @@ SELECT "ENQUIRY_ID","QUOTE_ID","ENTY_CODE","MODULE_CODE","LEAD_TIME","ADDITIONAL ,get_quote_items(qute_id) AS additional_items ,MAX(t.bas_code) over(PARTITION BY qute_id) AS bas_code ,MAX(t.qmax) over(PARTITION BY qute_id) AS qmax + ,MAX(t.qmin) over(PARTITION BY qute_id) AS qmin ,MAX(t.inlet_orientation) over(PARTITION BY qute_id) AS inlet_orientation ,MAX(t.outlet_orientation) over(PARTITION BY qute_id) AS outlet_orientation ,SUM(nvl(t.selling_price @@ -39,6 +40,7 @@ COMMENT ON COLUMN v_quote_details.lead_time IS 'The lead time for installation. COMMENT ON COLUMN v_quote_details.additional_items IS 'Any additional items included in the quote.'; COMMENT ON COLUMN v_quote_details.bas_code IS 'The module base code.'; COMMENT ON COLUMN v_quote_details.qmax IS 'The meter module''s Q max.'; +COMMENT ON COLUMN v_quote_details.qmin IS 'The meter module''s Q min.'; COMMENT ON COLUMN v_quote_details.inlet_orientation IS 'The orientation of the meter inlet.'; COMMENT ON COLUMN v_quote_details.outlet_orientation IS 'The orientatino of the meter outlet.'; COMMENT ON COLUMN v_quote_details.total_cost IS 'The total cost of the quote. This figure excludes any lifting gear or purging.';