DBA Data[Home] [Help]

APPS.MSC_CL_PRE_PROCESS dependencies on MSC_ST_SHIFT_EXCEPTIONS

Line 3494: ELSIF p_table_name = 'MSC_ST_SHIFT_EXCEPTIONS' THEN

3490: p_transaction_id,
3491: v_instance_code,
3492: p_calendar_code;
3493:
3494: ELSIF p_table_name = 'MSC_ST_SHIFT_EXCEPTIONS' THEN
3495:
3496: v_sql_stmt := 5;
3497: lv_sql_stmt :=
3498: 'UPDATE msc_st_shift_exceptions'

Line 3498: 'UPDATE msc_st_shift_exceptions'

3494: ELSIF p_table_name = 'MSC_ST_SHIFT_EXCEPTIONS' THEN
3495:
3496: v_sql_stmt := 5;
3497: lv_sql_stmt :=
3498: 'UPDATE msc_st_shift_exceptions'
3499: ||' set process_flag = '||G_ERROR_FLG||','
3500: ||' error_text = :p_message_text'
3501: ||' WHERE st_transaction_id = :p_transaction_id'
3502: ||' AND sr_instance_code = :instance_code'

Line 3592: 'UPDATE msc_st_shift_exceptions'

3588: p_calendar_code;
3589:
3590: v_sql_stmt := 11;
3591: lv_sql_stmt :=
3592: 'UPDATE msc_st_shift_exceptions'
3593: ||' set process_flag = '||G_PROPAGATION
3594: ||' WHERE sr_instance_code = :instance_code'
3595: ||' AND process_flag = '||G_IN_PROCESS
3596: ||' AND calendar_code = :calendar_code';

Line 3628: | tables msc_st_shift_exceptions and msc_st_shift_times |

3624: /*==========================================================================+
3625: | DESCRIPTION : This function inserts a record into the LID table for the |
3626: | new shifts, derives the shift information from the |
3627: | workday pattern table and updates the shift_num in the |
3628: | tables msc_st_shift_exceptions and msc_st_shift_times |
3629: +==========================================================================*/
3630: FUNCTION derive_shift_details
3631: (p_transaction_id NUMBER,
3632: p_company_name VARCHAR2,

Line 3722: 'UPDATE msc_st_shift_exceptions '

3718: v_instance_code;
3719:
3720: v_sql_stmt := 5;
3721: lv_sql_stmt :=
3722: 'UPDATE msc_st_shift_exceptions '
3723: ||' SET shift_num = :lv_shift_num'
3724: ||' WHERE calendar_code = :p_calendar_code'
3725: ||' AND shift_name = :p_shift_name'
3726: ||' AND process_flag = '||G_IN_PROCESS

Line 3879: FROM msc_st_shift_exceptions

3875: shift_name,
3876: exception_date,
3877: exception_type,
3878: deleted_flag
3879: FROM msc_st_shift_exceptions
3880: WHERE sr_instance_code = v_instance_code
3881: AND calendar_code = p_calendar_code
3882: AND process_flag = G_IN_PROCESS;
3883:

Line 4893: --validation for the table msc_st_shift_exceptions.

4889: END IF;
4890:
4891: END LOOP;
4892:
4893: --validation for the table msc_st_shift_exceptions.
4894: --Added to fix the bug#2748859
4895:
4896: --Getting the error message text
4897: lv_return := MSC_ST_UTIL.GET_ERROR_MESSAGE

Line 4909: UPDATE msc_st_shift_exceptions mc1

4905: END IF;
4906:
4907: --Duplicate records check for the records whose source is XML
4908:
4909: UPDATE msc_st_shift_exceptions mc1
4910: SET process_flag = G_ERROR_FLG,
4911: error_text = lv_message_text
4912: WHERE message_id < (SELECT MAX(message_id)
4913: FROM msc_st_shift_exceptions mc2

Line 4913: FROM msc_st_shift_exceptions mc2

4909: UPDATE msc_st_shift_exceptions mc1
4910: SET process_flag = G_ERROR_FLG,
4911: error_text = lv_message_text
4912: WHERE message_id < (SELECT MAX(message_id)
4913: FROM msc_st_shift_exceptions mc2
4914: WHERE mc2.sr_instance_code = mc1.sr_instance_code
4915: AND mc2.calendar_code = mc1.calendar_code
4916: AND mc2.exception_date = mc1.exception_date
4917: AND nvl(mc2.shift_name,NULL_CHAR) = nvl(mc1.shift_name,NULL_CHAR)

Line 4941: UPDATE msc_st_shift_exceptions mc1

4937: --Duplicate records check for the records whose source is other than XML
4938: --Different SQL is used because in XML we can identify the latest records
4939: --whereas in batch load we cannot.
4940:
4941: UPDATE msc_st_shift_exceptions mc1
4942: SET process_flag = G_ERROR_FLG,
4943: error_text = lv_message_text
4944: WHERE EXISTS( SELECT 1
4945: FROM msc_st_shift_exceptions mc2

Line 4945: FROM msc_st_shift_exceptions mc2

4941: UPDATE msc_st_shift_exceptions mc1
4942: SET process_flag = G_ERROR_FLG,
4943: error_text = lv_message_text
4944: WHERE EXISTS( SELECT 1
4945: FROM msc_st_shift_exceptions mc2
4946: WHERE mc2.sr_instance_code = mc1.sr_instance_code
4947: AND mc2.calendar_code = mc1.calendar_code
4948: AND mc2.exception_date = mc1.exception_date
4949: AND nvl(mc2.shift_name,NULL_CHAR) = nvl(mc1.shift_name,NULL_CHAR)

Line 4963: lv_table_name := 'MSC_ST_SHIFT_EXCEPTIONS';

4959: --Added to fix the bug#2748859
4960:
4961: FOR rec5 IN c5(rec1.calendar_code)
4962: LOOP
4963: lv_table_name := 'MSC_ST_SHIFT_EXCEPTIONS';
4964: lv_column_names :=
4965: 'CALENDAR_CODE ||''~''||'
4966: ||'EXCEPTION_DATE ||''~''||'
4967: ||'EXCEPTION_TYPE ||''~''||'

Line 4976: SELECT msc_st_shift_exceptions_s.NEXTVAL

4972: ||'EXCEPTION_SET_ID||''~''||'
4973: ||'DELETED_FLAG';
4974:
4975: v_sql_stmt := 22;
4976: SELECT msc_st_shift_exceptions_s.NEXTVAL
4977: INTO lv_transaction_id
4978: FROM dual;
4979:
4980: v_sql_stmt := 23;

Line 4981: UPDATE msc_st_shift_exceptions

4977: INTO lv_transaction_id
4978: FROM dual;
4979:
4980: v_sql_stmt := 23;
4981: UPDATE msc_st_shift_exceptions
4982: SET st_transaction_id = lv_transaction_id,
4983: refresh_id = v_refresh_id,
4984: exception_set_id = -1,
4985: last_update_date = v_current_date,

Line 4998: p_token_value1 => 'MSC_ST_SHIFT_EXCEPTIONS');

4994: p_error_code => 'MSC_PP_NO_DELETION',
4995: p_message_text => lv_message_text,
4996: p_error_text => lv_error_text,
4997: p_token1 => 'TABLE_NAME',
4998: p_token_value1 => 'MSC_ST_SHIFT_EXCEPTIONS');
4999:
5000: IF lv_return <> 0 THEN
5001: RAISE ex_logging_err;
5002: END IF;

Line 5065: ' UPDATE msc_st_shift_exceptions mc'

5061:
5062: IF v_instance_type = G_SCE then
5063: v_sql_stmt := 24;
5064: lv_sql_stmt :=
5065: ' UPDATE msc_st_shift_exceptions mc'
5066: ||' SET company_id = (SELECT party_id '
5067: ||' FROM hz_parties hp'
5068: ||' WHERE hp.party_name = mc.company_name)'
5069: ||' WHERE st_transaction_id = :lv_transaction_id ';

Line 5092: ' UPDATE msc_st_shift_exceptions'

5088: END IF;
5089: ELSE
5090: v_sql_stmt := 25;
5091: lv_sql_stmt :=
5092: ' UPDATE msc_st_shift_exceptions'
5093: ||' SET company_id = '||G_COMPANY_ID
5094: ||' WHERE st_transaction_id = :lv_transaction_id ';
5095:
5096: MSC_UTIL.LOG_MSG(MSC_UTIL.G_LVL_DEBUG_1,lv_sql_stmt);

Line 5118: (p_table_name => 'MSC_ST_SHIFT_EXCEPTIONS',

5114:
5115: --Logging a warning for those records where the deleted_flag value
5116: --is other than Yes/No.
5117: lv_return := MSC_ST_UTIL.LOG_ERROR
5118: (p_table_name => 'MSC_ST_SHIFT_EXCEPTIONS',
5119: p_instance_code => v_instance_code,
5120: p_row => lv_column_names,
5121: p_severity => G_SEV_WARNING,
5122: p_message_text => lv_message_text,

Line 5140: pEntityName => 'MSC_ST_SHIFT_EXCEPTIONS',

5136: (ERRBUF => lv_error_text,
5137: RETCODE => lv_return,
5138: pBatchID => null,
5139: pInstanceCode => v_instance_code,
5140: pEntityName => 'MSC_ST_SHIFT_EXCEPTIONS',
5141: pInstanceID => v_instance_id);
5142:
5143: IF lv_return <> 0 THEN
5144: RAISE ex_logging_err;

Line 5218: (p_table_name => 'MSC_ST_SHIFT_EXCEPTIONS',

5214: RAISE ex_logging_err;
5215: END IF;
5216:
5217: lv_return := MSC_ST_UTIL.SET_PROCESS_FLAG
5218: (p_table_name => 'MSC_ST_SHIFT_EXCEPTIONS',
5219: p_instance_id => v_instance_id,
5220: p_instance_code => v_instance_code,
5221: p_process_flag => G_VALID,
5222: p_where_str => lv_where_str,

Line 5593: ||' FROM msc_st_shift_exceptions'

5589: ||' program_id,'
5590: ||' program_update_date,'
5591: ||' refresh_id,'
5592: ||' exception_set_id'
5593: ||' FROM msc_st_shift_exceptions'
5594: ||' WHERE calendar_code = :calendar_code'
5595: ||' AND sr_instance_code = :sr_instance_code'
5596: ||' AND process_flag = '||G_VALID;
5597:

Line 5637: ' DELETE FROM msc_st_shift_exceptions '

5633:
5634: v_sql_stmt := 41;
5635:
5636: lv_sql_stmt :=
5637: ' DELETE FROM msc_st_shift_exceptions '
5638: ||' WHERE calendar_code = :calendar_code'
5639: ||' AND sr_instance_code = :sr_instance_code'
5640: ||' AND process_flag = '||G_VALID;
5641:

Line 50941: lv_count:= SET_IN_PROCESS (p_table_name => 'MSC_ST_SHIFT_EXCEPTIONS');

50937: lv_count:= SET_IN_PROCESS (p_table_name => 'MSC_ST_CALENDARS');
50938: lv_count:= SET_IN_PROCESS (p_table_name => 'MSC_ST_WORKDAY_PATTERNS');
50939: lv_count:= SET_IN_PROCESS (p_table_name => 'MSC_ST_CALENDAR_SHIFTS');
50940: lv_count:= SET_IN_PROCESS (p_table_name => 'MSC_ST_SHIFT_TIMES');
50941: lv_count:= SET_IN_PROCESS (p_table_name => 'MSC_ST_SHIFT_EXCEPTIONS');
50942: lv_count:= SET_IN_PROCESS (p_table_name => 'MSC_ST_CALENDAR_EXCEPTIONS');
50943: END IF;
50944:
50945: IF v_rtg_enabled = SYS_YES THEN