DBA Data[Home] [Help]

APPS.MSD_DEM_COMMON_UTILITIES dependencies on STANDARD

Line 31: CURSOR standard_conversions IS

27:
28: from_class varchar2(10);
29: to_class varchar2(10);
30:
31: CURSOR standard_conversions IS
32: select t.conversion_rate std_to_rate,
33: t.uom_class std_to_class,
34: f.conversion_rate std_from_rate,
35: f.uom_class std_from_class

Line 47: std_rec standard_conversions%rowtype;

43: nvl(f.disable_date, trunc(sysdate) + 1) > trunc(sysdate)
44: order by t.inventory_item_id desc, f.inventory_item_id desc;
45:
46:
47: std_rec standard_conversions%rowtype;
48:
49:
50: CURSOR interclass_conversions(p_from_class VARCHAR2, p_to_class VARCHAR2) IS
51: select decode(from_uom_class, p_from_class, 1, 2) from_flag,

Line 93: ** standard conversion, which is defined for all items, is used.

89: **
90: ** 1. The conversion always starts from the conversion defined, if exists,
91: ** for an specified item.
92: ** 2. If the conversion id not defined for that specific item, then the
93: ** standard conversion, which is defined for all items, is used.
94: ** 3. When the conversion involves two different classes, then
95: ** interclass conversion is activated.
96: */
97:

Line 107: /* Get item specific or standard conversions */

103: goto procedure_end;
104: end if;
105:
106:
107: /* Get item specific or standard conversions */
108: open standard_conversions;
109: std_index := 0;
110: loop
111:

Line 108: open standard_conversions;

104: end if;
105:
106:
107: /* Get item specific or standard conversions */
108: open standard_conversions;
109: std_index := 0;
110: loop
111:
112: std_index := std_index + 1;

Line 114: fetch standard_conversions into std_rec;

110: loop
111:
112: std_index := std_index + 1;
113:
114: fetch standard_conversions into std_rec;
115: exit when standard_conversions%notfound;
116:
117: from_rate_tab(std_index) := std_rec.std_from_rate;
118: from_class_tab(std_index) := std_rec.std_from_class;

Line 115: exit when standard_conversions%notfound;

111:
112: std_index := std_index + 1;
113:
114: fetch standard_conversions into std_rec;
115: exit when standard_conversions%notfound;
116:
117: from_rate_tab(std_index) := std_rec.std_from_rate;
118: from_class_tab(std_index) := std_rec.std_from_class;
119: to_rate_tab(std_index) := std_rec.std_to_rate;

Line 124: close standard_conversions;

120: to_class_tab(std_index) := std_rec.std_to_class;
121:
122: end loop;
123:
124: close standard_conversions;
125:
126: if (std_index = 0) then /* No conversions defined */
127: msgbuf := msgbuf||'Invalid standard conversion : ';
128: msgbuf := msgbuf||'From UOM code: '||from_unit||' ';

Line 127: msgbuf := msgbuf||'Invalid standard conversion : ';

123:
124: close standard_conversions;
125:
126: if (std_index = 0) then /* No conversions defined */
127: msgbuf := msgbuf||'Invalid standard conversion : ';
128: msgbuf := msgbuf||'From UOM code: '||from_unit||' ';
129: msgbuf := msgbuf||'To UOM code: '||to_unit||' ';
130: raise invalid_conversion;
131:

Line 182: ** so seperate calculations are not required for standard/interclass

178: end if; /* End of from_class <> to_class */
179:
180: /*
181: ** conversion rates are defaulted to '1' at the start of the procedure
182: ** so seperate calculations are not required for standard/interclass
183: ** conversions
184: */
185:
186: if (to_rate <> 0 ) then

Line 705: /* Start with dropping the standard error columns in the ERR table */

701:
702: IF (x_count1 = 0)
703: THEN
704:
705: /* Start with dropping the standard error columns in the ERR table */
706: x_sql := 'ALTER TABLE ' || x_dem_schema || '.T_SRC_SALES_TMPL_ERR '
707: || ' DROP (ERROR_CODE_RECORD, LOAD_DATE, ERROR_MESSAGE_RECORD) ';
708: EXECUTE IMMEDIATE x_sql;
709: log_message ('Dropping columns ERROR_CODE_RECORD, LOAD_DATE and ERROR_MESSAGE_RECORD from Demantra table T_SRC_SALES_TMPL_ERR');

Line 781: /* Add back the standard error columns in the ERR table */

777: log_message ('Adding column EBS_BASE_MODEL_CODE to T_SRC_SALES_TMPL_ERR');
778:
779: END IF;
780:
781: /* Add back the standard error columns in the ERR table */
782: x_sql := 'ALTER TABLE ' || x_dem_schema || '.T_SRC_SALES_TMPL_ERR '
783: || ' ADD (ERROR_CODE_RECORD NUMBER(2), LOAD_DATE DATE, ERROR_MESSAGE_RECORD VARCHAR2(2000)) ';
784: EXECUTE IMMEDIATE x_sql;
785: log_message ('Adding columns ERROR_CODE_RECORD, LOAD_DATE and ERROR_MESSAGE_RECORD to Demantra table T_SRC_SALES_TMPL_ERR');

Line 867: /* Dropping the standard error columns in the ERR table */

863: EXECUTE IMMEDIATE 'ALTER TABLE ' || x_dem_schema || '.T_SRC_LOC_TMPL '
864: || ' ADD (T_EP_LR2A_DESC VARCHAR2(100)) ';
865: log_message ('Adding column T_EP_LR2A_DESC to T_SRC_LOC_TMPL');
866:
867: /* Dropping the standard error columns in the ERR table */
868: x_sql := 'ALTER TABLE ' || x_dem_schema || '.T_SRC_LOC_TMPL_ERR '
869: || ' DROP (ERROR_CODE_RECORD, LOAD_DATE, ERROR_MESSAGE_RECORD) ';
870: EXECUTE IMMEDIATE x_sql;
871: log_message ('Dropping columns ERROR_CODE_RECORD, LOAD_DATE and ERROR_MESSAGE_RECORD from Demantra table T_SRC_LOC_TMPL_ERR');

Line 878: /* Add back the standard error columns in the ERR table */

874: EXECUTE IMMEDIATE 'ALTER TABLE ' || x_dem_schema || '.T_SRC_LOC_TMPL_ERR '
875: || ' ADD (T_EP_LR2A_DESC VARCHAR2(100)) ';
876: log_message ('Adding column T_EP_LR2A_DESC to T_SRC_LOC_TMPL_ERR');
877:
878: /* Add back the standard error columns in the ERR table */
879: x_sql := 'ALTER TABLE ' || x_dem_schema || '.T_SRC_LOC_TMPL_ERR '
880: || ' ADD (ERROR_CODE_RECORD NUMBER(2), LOAD_DATE DATE, ERROR_MESSAGE_RECORD VARCHAR2(2000)) ';
881: EXECUTE IMMEDIATE x_sql;
882: log_message ('Adding columns ERROR_CODE_RECORD, LOAD_DATE and ERROR_MESSAGE_RECORD to Demantra table T_SRC_LOC_TMPL_ERR');