454:
455: BEGIN
456: /* BEGIN
457: select 1 into calendar_is_not_seeded
458: from dual
459: where exists ( select 'exists'
460: from msc_calendar_dates
461: where calendar_code = 'CP-Mon-70'
462: and exception_set_id = -1
830: WHERE ln.parent_header_id = p_header_id AND
831: ln.line_id = t_line_id(j) AND
832: NVL(ln.row_status, G_PROCESS) = G_PROCESS AND
833: not exists ( select 1
834: from dual
835: where upper(ln.posting_party_name) =
836: upper(nvl(ln.supplier_company,G_NULL_STRING))
837: union select 1
838: from dual
834: from dual
835: where upper(ln.posting_party_name) =
836: upper(nvl(ln.supplier_company,G_NULL_STRING))
837: union select 1
838: from dual
839: where upper(ln.posting_party_name) =
840: upper(nvl(ln.customer_company,G_NULL_STRING))
841: union select 1
842: from dual
838: from dual
839: where upper(ln.posting_party_name) =
840: upper(nvl(ln.customer_company,G_NULL_STRING))
841: union select 1
842: from dual
843: where upper(ln.posting_party_name) =
844: upper(nvl(ln.publisher_company,G_NULL_STRING))
845: );
846: end if;
1540: WHERE ln.parent_header_id = p_header_id AND
1541: ln.line_id = t_line_id1(j) AND
1542: NVL(ln.row_status, G_PROCESS) = G_PROCESS AND
1543: not exists ( select 1
1544: from dual
1545: where upper(ln.posting_party_name) =
1546: upper(nvl(ln.supplier_company,G_NULL_STRING))
1547: union select 1
1548: from dual
1544: from dual
1545: where upper(ln.posting_party_name) =
1546: upper(nvl(ln.supplier_company,G_NULL_STRING))
1547: union select 1
1548: from dual
1549: where upper(ln.posting_party_name) =
1550: upper(nvl(ln.customer_company,G_NULL_STRING))
1551: union select 1
1552: from dual
1548: from dual
1549: where upper(ln.posting_party_name) =
1550: upper(nvl(ln.customer_company,G_NULL_STRING))
1551: union select 1
1552: from dual
1553: where upper(ln.posting_party_name) =
1554: upper(nvl(ln.publisher_company,G_NULL_STRING))
1555: );
1556: end if;
7100: --Raise event that launches the workflow process that sends the error message
7101: --============================================================================
7102: BEGIN
7103: SELECT 1 INTO l_error_count
7104: FROM dual
7105: WHERE exists(
7106: SELECT 'exists'
7107: FROM msc_supdem_lines_interface
7108: WHERE parent_header_id = p_header_id AND
7217: log_message('Calculating average demand');
7218: BEGIN
7219: select 1
7220: into l_comp_avg_dmd
7221: from dual
7222: where exists (
7223: select 'exists'
7224: from msc_supdem_lines_interface ln,
7225: fnd_lookup_values flv
7271: l_msc_x_configuration := FND_PROFILE.VALUE('MSC_X_CONFIGURATION');
7272: BEGIN
7273: select 1
7274: into l_order_type_flag
7275: from dual
7276: where exists (
7277: select 'exists'
7278: from msc_supdem_lines_interface ln,
7279: fnd_lookup_values flv
9033: tmpDate DATE;
9034: BEGIN
9035: SELECT to_date(p_string, 'YYYYMMDD HH24MISS')
9036: INTO tmpDate
9037: FROM dual;
9038:
9039: SELECT to_char(tmpDate, 'DD/MM/YYYY HH24:MI:SS')
9040: INTO p_string
9041: FROM dual;
9037: FROM dual;
9038:
9039: SELECT to_char(tmpDate, 'DD/MM/YYYY HH24:MI:SS')
9040: INTO p_string
9041: FROM dual;
9042:
9043: EXCEPTION when others then
9044: LOG_MESSAGE('Error in msc_sce_loads_pkg.change_date_format');
9045: LOG_MESSAGE(SQLERRM);