DBA Data[Home] [Help]

APPS.GL_CRM_UTILITIES_PKG dependencies on GL_DAILY_RATES_INTERFACE

Line 468: FROM gl_daily_rates_interface dri,

464: dct.conversion_type,
465: dri.conversion_rate,
466: NVL(dri.inverse_conversion_rate, 1/conversion_rate) inverse_conversion_rate,
467: dri.mode_flag
468: FROM gl_daily_rates_interface dri,
469: gl_daily_conversion_types dct
470: WHERE mode_flag IN ('I', 'D', 'T', 'N')
471: AND dct.user_conversion_type = dri.user_conversion_type
472: AND dri.batch_number = l_batch_number;

Line 492: /*If the Batch Number is NULL, it'll process only the records with Batch Number NULL records in the GL_DAILY_RATES_INTERFACE Table.*/

488: -- If there is any error, an appropriate error_code will be set.
489: gl_message.func_ent('Daily Rates Import');
490:
491: -- GL_CRM_UTILITIES_PKG.DEBUG_MODE := TRUE;
492: /*If the Batch Number is NULL, it'll process only the records with Batch Number NULL records in the GL_DAILY_RATES_INTERFACE Table.*/
493: /* Updating BATCH_NUMNER '-99999' in the Interface table if Batch Number Parameter is NULL*/
494: IF l_batch_number IS NULL THEN
495: UPDATE gl_daily_rates_interface ri
496: SET ERROR_CODE =

Line 495: UPDATE gl_daily_rates_interface ri

491: -- GL_CRM_UTILITIES_PKG.DEBUG_MODE := TRUE;
492: /*If the Batch Number is NULL, it'll process only the records with Batch Number NULL records in the GL_DAILY_RATES_INTERFACE Table.*/
493: /* Updating BATCH_NUMNER '-99999' in the Interface table if Batch Number Parameter is NULL*/
494: IF l_batch_number IS NULL THEN
495: UPDATE gl_daily_rates_interface ri
496: SET ERROR_CODE =
497: (SELECT DECODE
498: (ct.ROWID,
499: NULL, 'NONEXISTANT_CONVERSION_TYPE',

Line 604: FROM gl_daily_rates_interface ri2,

600: 1),
601: -1, 'EMU_TO_CURRENCY',
602: 0, 'EMU_TO_CURRENCY',
603: ''))))))))))))))))))
604: FROM gl_daily_rates_interface ri2,
605: gl_daily_conversion_types ct,
606: fnd_currencies from_curr,
607: fnd_currencies to_curr
608: WHERE ri2.ROWID = ri.ROWID

Line 616: UPDATE GL_DAILY_RATES_INTERFACE T1

612: ri.batch_number = DECODE(l_batch_number,null,-99999,ri.batch_number)
613: WHERE ri.mode_flag IN('I', 'D', 'T', 'N')
614: AND ri.batch_number is NULL;
615:
616: UPDATE GL_DAILY_RATES_INTERFACE T1
617: SET T1.error_code = 'DUPLICATE_ROWS'
618: WHERE
619: (T1.FROM_CURRENCY,T1.TO_CURRENCY,T1.USER_CONVERSION_TYPE,
620: T1.FROM_CONVERSION_DATE, T1.TO_CONVERSION_DATE)

Line 625: FROM GL_DAILY_RATES_INTERFACE T2

621: IN
622: (
623: SELECT /*+ NO_MERGE */ T2.FROM_CURRENCY,T2.to_CURRENCY,T2.USER_CONVERSION_TYPE,
624: T2.FROM_CONVERSION_DATE, T2.TO_CONVERSION_DATE
625: FROM GL_DAILY_RATES_INTERFACE T2
626: WHERE mode_flag IN ('I', 'D', 'T', 'N')
627: GROUP BY T2.FROM_CURRENCY,T2.TO_CURRENCY,T2.USER_CONVERSION_TYPE,
628: T2.FROM_CONVERSION_DATE, T2.TO_CONVERSION_DATE
629: HAVING count(*) > 1)

Line 637: UPDATE gl_daily_rates_interface ri

633:
634: l_batch_number := '-99999';
635:
636: ELSE
637: UPDATE gl_daily_rates_interface ri
638: SET ERROR_CODE =
639: (SELECT DECODE
640: (ct.ROWID,
641: NULL, 'NONEXISTANT_CONVERSION_TYPE',

Line 746: FROM gl_daily_rates_interface ri2,

742: 1),
743: -1, 'EMU_TO_CURRENCY',
744: 0, 'EMU_TO_CURRENCY',
745: ''))))))))))))))))))
746: FROM gl_daily_rates_interface ri2,
747: gl_daily_conversion_types ct,
748: fnd_currencies from_curr,
749: fnd_currencies to_curr
750: WHERE ri2.ROWID = ri.ROWID

Line 757: UPDATE GL_DAILY_RATES_INTERFACE T1

753: AND to_curr.currency_code(+) = ri2.to_currency)
754: WHERE ri.mode_flag IN('I', 'D', 'T', 'N')
755: AND ri.batch_number = l_batch_number;
756:
757: UPDATE GL_DAILY_RATES_INTERFACE T1
758: SET T1.error_code = 'DUPLICATE_ROWS'
759: WHERE
760: (T1.FROM_CURRENCY,T1.TO_CURRENCY,T1.USER_CONVERSION_TYPE,
761: T1.FROM_CONVERSION_DATE, T1.TO_CONVERSION_DATE)

Line 766: FROM GL_DAILY_RATES_INTERFACE T2

762: IN
763: (
764: SELECT /*+ NO_MERGE */ T2.FROM_CURRENCY,T2.to_CURRENCY,T2.USER_CONVERSION_TYPE,
765: T2.FROM_CONVERSION_DATE, T2.TO_CONVERSION_DATE
766: FROM GL_DAILY_RATES_INTERFACE T2
767: WHERE mode_flag IN ('I', 'D', 'T', 'N')
768: GROUP BY T2.FROM_CURRENCY,T2.TO_CURRENCY,T2.USER_CONVERSION_TYPE,
769: T2.FROM_CONVERSION_DATE, T2.TO_CONVERSION_DATE
770: HAVING count(*) > 1)

Line 781: UPDATE gl_daily_rates_interface

777: -- N - no override GL rates
778: -- T - Treasury Insert (override existing GL rates).
779: /*
780: -- Update mode flag to 'X' for each erroneous row
781: UPDATE gl_daily_rates_interface
782: SET mode_flag = 'X'
783: WHERE mode_flag IN('I', 'D') AND ERROR_CODE IS NOT NULL;
784:
785: -- Update mode flag to 'X' for each erroneous row from Treasury

Line 786: UPDATE gl_daily_rates_interface

782: SET mode_flag = 'X'
783: WHERE mode_flag IN('I', 'D') AND ERROR_CODE IS NOT NULL;
784:
785: -- Update mode flag to 'X' for each erroneous row from Treasury
786: UPDATE gl_daily_rates_interface
787: SET mode_flag = 'F'
788: WHERE mode_flag IN('T', 'N') AND ERROR_CODE IS NOT NULL;
789: */
790:

Line 793: UPDATE gl_daily_rates_interface ri

789: */
790:
791:
792: -- Update mode flag to X/F for each erroneous row
793: UPDATE gl_daily_rates_interface ri
794: SET mode_flag =
795: Decode(mode_flag,'T','F','N','F','I','X','D','X',mode_flag)
796: WHERE (mode_flag IN('T', 'N','I','D') AND batch_number = l_batch_number AND ERROR_CODE IS NOT NULL)
797: OR (mode_flag = 'N'

Line 823: FROM gl_daily_rates_interface

819:
820: BEGIN
821: SELECT 'E'
822: INTO l_return_status
823: FROM gl_daily_rates_interface
824: WHERE mode_flag in ('X','F')
825: AND batch_number = l_batch_number
826: AND ROWNUM < 2;
827:

Line 834: UPDATE gl_daily_rates_interface

830: l_return_status := 'S';
831: END;
832:
833:
834: UPDATE gl_daily_rates_interface
835: SET inverse_conversion_rate = 1 / conversion_rate
836: WHERE inverse_conversion_rate IS NULL AND conversion_rate > 0
837: AND batch_number = l_batch_number;
838:

Line 842: 'Finish Validation on GL_DAILY_RATES_INTERFACE table.');

838:
839: IF DEBUG_MODE THEN
840: fnd_file.put_line
841: (fnd_file.LOG,
842: 'Finish Validation on GL_DAILY_RATES_INTERFACE table.');
843: END IF;
844:
845: SELECT from_currency,
846: to_currency,

Line 877: FROM gl_daily_rates_interface

873: daily_rate_validation_failure.r_type,
874: daily_rate_validation_failure.r_rate,
875: daily_rate_validation_failure.r_inverse_rate,
876: daily_rate_validation_failure.r_error_code
877: FROM gl_daily_rates_interface
878: WHERE mode_flag IN('X', 'F')
879: AND batch_number = l_batch_number;
880:
881: FOR i IN 1 .. daily_rate_validation_failure.r_from_curr.COUNT LOOP

Line 965: gl_daily_rates_interface ri

961: FROM gl_daily_rates dr,
962: gl_daily_conversion_types gldct,
963: gl_row_multipliers rm,
964: gl_daily_conversion_types ct,
965: gl_daily_rates_interface ri
966: WHERE ri.mode_flag = 'D'
967: AND ct.user_conversion_type = ri.user_conversion_type || ''
968: AND rm.multiplier BETWEEN 1 AND (TRUNC(ri.to_conversion_date)
969: - TRUNC(ri.from_conversion_date)

Line 1048: gl_daily_rates_interface ri

1044: FROM gl_daily_rates dr,
1045: gl_daily_conversion_types gldct,
1046: gl_row_multipliers rm,
1047: gl_daily_conversion_types ct,
1048: gl_daily_rates_interface ri
1049: WHERE ct.user_conversion_type = ri.user_conversion_type || ''
1050: AND rm.multiplier BETWEEN 1 AND (TRUNC(ri.to_conversion_date)
1051: - TRUNC(ri.from_conversion_date)
1052: + 1)

Line 1108: UPDATE gl_daily_rates_interface ri

1104:
1105: -- Update used_for_ab_translation = 'Y' if the currency and
1106: -- conversion type is used in average translation in the system
1107: -- R12 Change in the following update
1108: UPDATE gl_daily_rates_interface ri
1109: SET used_for_ab_translation =
1110: ( SELECT nvl(max('Y'), 'N')
1111: FROM gl_daily_conversion_types ct,
1112: gl_ledgers led,

Line 1133: FROM gl_daily_rates_interface

1129: BEGIN
1130:
1131: SELECT 'Y'
1132: INTO l_launch_rate_change
1133: FROM gl_daily_rates_interface
1134: WHERE used_for_ab_translation = 'Y'
1135: AND ROWNUM < 2;
1136:
1137: EXCEPTION

Line 1167: gl_daily_rates_interface ri

1163: TRUNC(ri.from_conversion_date) + rm.multiplier
1164: - 1
1165: FROM gl_row_multipliers rm,
1166: gl_daily_conversion_types ct,
1167: gl_daily_rates_interface ri
1168: WHERE ri.mode_flag = 'D'
1169: AND ri.batch_number = l_batch_number
1170: AND ri.used_for_ab_translation = 'Y'
1171: AND ct.user_conversion_type =

Line 1186: gl_daily_rates_interface ri

1182: TRUNC(ri.from_conversion_date) + rm.multiplier
1183: - 1
1184: FROM gl_row_multipliers rm,
1185: gl_daily_conversion_types ct,
1186: gl_daily_rates_interface ri
1187: WHERE ri.mode_flag = 'D'
1188: AND ri.batch_number = l_batch_number
1189: AND ri.used_for_ab_translation = 'Y'
1190: AND ct.user_conversion_type =

Line 1224: gl_daily_rates_interface ri

1220: TRUNC(ri.from_conversion_date)
1221: + rm.multiplier - 1
1222: FROM gl_row_multipliers rm,
1223: gl_daily_conversion_types ct,
1224: gl_daily_rates_interface ri
1225: WHERE ri.batch_number = l_batch_number
1226: AND ( ri.mode_flag IN('I', 'T')
1227: OR ( ri.mode_flag = 'D'
1228: AND ri.used_for_ab_translation <> 'Y'))

Line 1244: gl_daily_rates_interface ri

1240: TRUNC(ri.from_conversion_date)
1241: + rm.multiplier - 1
1242: FROM gl_row_multipliers rm,
1243: gl_daily_conversion_types ct,
1244: gl_daily_rates_interface ri
1245: WHERE ri.batch_number = l_batch_number
1246: AND ( ri.mode_flag IN('I', 'T')
1247: OR ( ri.mode_flag = 'D'
1248: AND ri.used_for_ab_translation <> 'Y'))

Line 1294: gl_daily_rates_interface ri

1290: ri.attribute14, ri.attribute15,
1291: DECODE(ri.mode_flag, 'T', 'TREASURY', 'N', 'TREASURY', 'USER')
1292: FROM gl_row_multipliers rm,
1293: gl_daily_conversion_types ct,
1294: gl_daily_rates_interface ri
1295: WHERE ri.mode_flag IN('I', 'T', 'N')
1296: AND ct.user_conversion_type = ri.user_conversion_type || ''
1297: AND rm.multiplier BETWEEN 1
1298: AND TRUNC(ri.to_conversion_date)

Line 1327: gl_daily_rates_interface ri

1323: ri.attribute14, ri.attribute15,
1324: DECODE(ri.mode_flag, 'T', 'TREASURY', 'N', 'TREASURY', 'USER')
1325: FROM gl_row_multipliers rm,
1326: gl_daily_conversion_types ct,
1327: gl_daily_rates_interface ri
1328: WHERE ri.mode_flag IN('I', 'T', 'N')
1329: AND ct.user_conversion_type = ri.user_conversion_type || ''
1330: AND rm.multiplier BETWEEN 1
1331: AND TRUNC(ri.to_conversion_date)

Line 1400: FROM gl_daily_rates_interface

1396:
1397: --- Cross Rates Calculation ---
1398: SELECT COUNT(*)
1399: INTO rows_need_calculation
1400: FROM gl_daily_rates_interface
1401: WHERE mode_flag IN('I', 'D', 'T', 'N')
1402: AND user_conversion_type IN(
1403: SELECT user_conversion_type
1404: FROM gl_daily_conversion_types gct,

Line 1421: -- Delete all valid rows in GL_DAILY_RATES_INTERFACE and do not need

1417: END IF;
1418: END IF;
1419:
1420: IF rows_need_calculation > 0 THEN
1421: -- Delete all valid rows in GL_DAILY_RATES_INTERFACE and do not need
1422: -- crossing rates calculation
1423: DELETE FROM gl_daily_rates_interface
1424: WHERE mode_flag IN('I', 'D', 'T', 'N')
1425: AND batch_number = l_batch_number

Line 1423: DELETE FROM gl_daily_rates_interface

1419:
1420: IF rows_need_calculation > 0 THEN
1421: -- Delete all valid rows in GL_DAILY_RATES_INTERFACE and do not need
1422: -- crossing rates calculation
1423: DELETE FROM gl_daily_rates_interface
1424: WHERE mode_flag IN('I', 'D', 'T', 'N')
1425: AND batch_number = l_batch_number
1426: AND user_conversion_type NOT IN(
1427: SELECT user_conversion_type

Line 1470: FROM gl_daily_rates_interface gldri,

1466: glcrs.pivot_currency, gldri.inverse_conversion_rate,
1467: gldri.conversion_rate),
1468: DECODE(gldri.mode_flag, 'D', 'D', 'I'),
1469: gldri.used_for_ab_translation
1470: FROM gl_daily_rates_interface gldri,
1471: gl_daily_conversion_types gldct,
1472: gl_cross_rate_rules glcrs,
1473: gl_cross_rate_rule_dtls glcrsd
1474: WHERE gldri.mode_flag IN('I', 'D', 'T', 'N')

Line 1715: -- GL_DAILY_RATES_INTERFACE where mode = 'D',

1711: 'Mark D for Cross Rates');
1712: END IF;
1713:
1714: -- For each row with conversion rate in
1715: -- GL_DAILY_RATES_INTERFACE where mode = 'D',
1716: -- set status_code to 'D' in the corresponding row in GL_DAILY_RATES.
1717: UPDATE gl_daily_rates gldr
1718: SET status_code = 'D'
1719: WHERE ( (gldr.rate_source_code IS NOT NULL

Line 2005: DELETE FROM gl_daily_rates_interface

2001: END IF;
2002:
2003: ---- End Calculation
2004:
2005: DELETE FROM gl_daily_rates_interface
2006: WHERE mode_flag IN('I', 'D', 'T', 'N')
2007: AND batch_number = l_batch_number;
2008:
2009: -- Launch the Rate Change Program if needed

Line 2043: DELETE FROM gl_daily_rates_interface

2039: ('WARNING',
2040: 'Exceptions occurs, please check the output for details.');
2041: END IF;
2042:
2043: DELETE FROM gl_daily_rates_interface
2044: WHERE mode_flag IN('I', 'D', 'T', 'N')
2045: AND batch_number = l_batch_number;
2046:
2047: --ekey := req_id;