1: PACKAGE BODY WSM_SPLIT_PERC_PVT AS
2: /* $Header: WSMCOSPB.pls 115.3 2004/05/27 07:49:02 mprathap noship $ */
3:
4: /*---------------------------------------------------------------------------+
5: | Procedure to insert a row in the split percentages table for a given |
122:
123: EXCEPTION
124: WHEN OTHERS THEN
125: x_err_code:= -1;
126: x_err_msg := 'WSM_SPLIT_PERC_PVT.insert_row :' || SQLCODE || ' :' || substr(SQLERRM,1,1000);
127: RETURN;
128: END insert_row;
129:
130: /*---------------------------------------------------------------------------+
212:
213: EXCEPTION
214: WHEN OTHERS THEN
215: x_err_code := -1;
216: x_err_msg := 'WSM_SPLIT_PERC_PVT.update_row :' || SQLCODE || ' :' || substr(SQLERRM,1,1000);
217: RETURN;
218:
219: END update_row;
220:
344:
345: EXCEPTION
346: WHEN OTHERS THEN
347: x_err_code := -1;
348: x_err_msg := 'WSM_SPLIT_PERC_PVT.lock_row :' || SQLCODE || ' :' || substr(SQLERRM,1,1000);
349: RETURN;
350: END lock_row;
351:
352: /*---------------------------------------------------------------------------+
372:
373: EXCEPTION
374: WHEN OTHERS THEN
375: x_err_code:= -1;
376: x_err_msg := 'WSM_SPLIT_PERC_PVT.delete_row :' || SQLCODE || ' :' || substr(SQLERRM,1,1000);
377: RETURN;
378: END delete_row;
379:
380: /*---------------------------------------------------------------------------+
396:
397: EXCEPTION
398: WHEN OTHERS THEN
399: x_err_code:= -1;
400: x_err_msg := 'WSM_SPLIT_PERC_PVT.delete_all_range :' || SQLCODE || ' :' || substr(SQLERRM,1,1000);
401: RETURN;
402: END delete_all_range;
403:
404:
643:
644: EXCEPTION
645: WHEN OTHERS THEN
646: x_err_code := -1;
647: x_err_msg := 'WSM_SPLIT_PERC_PVT .process_records : stmt : ' || stmt_num || ' ' || SQLCODE || ' :' || substr(SQLERRM,1,1000);
648: RETURN;
649: end process_records;
650:
651: /*---------------------------------------------------------------------------+
808:
809: EXCEPTION
810: WHEN OTHERS THEN
811: x_err_code := -1;
812: x_err_msg := 'WSM_SPLIT_PERC_PVT.update_split_range : ' || SQLCODE || substr(SQLERRM,1,1000);
813: RETURN;
814: END update_split_range;
815:
816: /*---------------------------------------------------------------------------+
866: value of p_effectivity_date and disable date passed... */
867:
868: IF (l_num=0) THEN
869: -- insert using the date data passed
870: WSM_SPLIT_PERC_PVT.insert_row(x_err_code => l_err_code,
871: x_err_msg => l_err_msg,
872: p_co_product_id => p_co_product_id,
873: p_co_product_group_id => p_co_product_group_id,
874: p_organization_id => p_organization_id,
892: -- so open the cursor and insert this data...
893: SAVEPOINT date_save;
894: FOR date_rec IN range_cursor LOOP
895: -- get the data and call the insert procedure....
896: WSM_SPLIT_PERC_PVT.insert_row(x_err_code => l_err_code,
897: x_err_msg => l_err_msg,
898: p_co_product_id => p_co_product_id,
899: p_co_product_group_id => p_co_product_group_id,
900: p_organization_id => p_organization_id,
919: END IF;
920: EXCEPTION
921: WHEN OTHERS THEN
922: x_err_code := -1;
923: x_err_msg := 'WSM_SPLIT_PERC_PVT.insert_co_product_range : ' || SQLCODE || substr(SQLERRM,1,1000);
924: RETURN;
925: END insert_co_product_range;
926:
927: /*---------------------------------------------------------------------------+
964: END;
965: EXCEPTION
966: WHEN OTHERS THEN
967: x_err_code := -1;
968: x_err_msg := 'WSM_SPLIT_PERC_PVT.check_split_perc_exists : ' || SQLCODE || substr(SQLERRM,1,1000);
969: RETURN TRUE;
970:
971: END check_split_perc_exists;
972:
1071:
1072: EXCEPTION
1073: WHEN OTHERS THEN
1074: x_err_code := -1;
1075: x_err_msg := 'WSM_SPLIT_PERC_PVT.check_split_perc_exists : ' || SQLCODE || substr(SQLERRM,1,1000);
1076: RETURN TRUE;
1077:
1078: END check_split_perc_exists;
1079:
1114: END IF;
1115: EXCEPTION
1116: WHEN OTHERS THEN
1117: x_err_code := -1;
1118: x_err_msg := 'WSM_SPLIT_PERC_PVT.check_unique_range : ' || SQLCODE || substr(SQLERRM,1,1000);
1119: RETURN TRUE;
1120: END check_unique_range;
1121:
1122: /*---------------------------------------------------------------------------+
1239:
1240: EXCEPTION
1241: WHEN OTHERS THEN
1242: x_err_code := -1;
1243: x_err_msg := 'WSM_SPLIT_PERC_PVT.check_unique : ' || SQLCODE || substr(SQLERRM,1,1000);
1244: RETURN TRUE;
1245:
1246: END check_unique;
1247:
1244: RETURN TRUE;
1245:
1246: END check_unique;
1247:
1248: END WSM_SPLIT_PERC_PVT;