66: IF(l_msg_count > 0) THEN
67: FOR i in 1 ..l_msg_count
68: LOOP
69: l_msg_data := FND_MSG_PUB.get(i, FND_API.g_false);
70: FND_FILE.PUT_LINE(FND_FILE.LOG, i ||'-'||l_msg_data);
71: END LOOP;
72: END IF;
73:
74: EXCEPTION
73:
74: EXCEPTION
75: when fnd_api.g_exc_error then
76: x_return_status := fnd_api.g_ret_sts_error;
77: fnd_file.put_line(fnd_file.log,'CST_Utility_PUB.writeLogMessages(' || l_stmt_num || '): ' || x_return_status || substr(SQLERRM,1,200));
78: when fnd_api.g_exc_unexpected_error then
79: x_return_status := fnd_api.g_ret_sts_unexp_error ;
80: fnd_file.put_line(fnd_file.log,'CST_Utility_PUB.writeLogMessages(' || l_stmt_num || '): ' || x_return_status || substr(SQLERRM,1,200));
81: when others then
76: x_return_status := fnd_api.g_ret_sts_error;
77: fnd_file.put_line(fnd_file.log,'CST_Utility_PUB.writeLogMessages(' || l_stmt_num || '): ' || x_return_status || substr(SQLERRM,1,200));
78: when fnd_api.g_exc_unexpected_error then
79: x_return_status := fnd_api.g_ret_sts_unexp_error ;
80: fnd_file.put_line(fnd_file.log,'CST_Utility_PUB.writeLogMessages(' || l_stmt_num || '): ' || x_return_status || substr(SQLERRM,1,200));
81: when others then
82: x_return_status := fnd_api.g_ret_sts_unexp_error ;
83: fnd_file.put_line(fnd_file.log,'CST_Utility_PUB.writeLogMessages(' || l_stmt_num || '): ' || x_return_status || substr(SQLERRM,1,200));
84:
79: x_return_status := fnd_api.g_ret_sts_unexp_error ;
80: fnd_file.put_line(fnd_file.log,'CST_Utility_PUB.writeLogMessages(' || l_stmt_num || '): ' || x_return_status || substr(SQLERRM,1,200));
81: when others then
82: x_return_status := fnd_api.g_ret_sts_unexp_error ;
83: fnd_file.put_line(fnd_file.log,'CST_Utility_PUB.writeLogMessages(' || l_stmt_num || '): ' || x_return_status || substr(SQLERRM,1,200));
84:
85: END writeLogMessages;
86:
87: ----------------------------------------------------------------------------
541:
542: l_debug := FND_PROFILE.VALUE('MRP_DEBUG');
543: if (l_debug = 'Y') then
544: l_api_message := 'insert_MTA API: Txn ID = '||to_char(P_TXN_ID);
545: FND_FILE.PUT_LINE(fnd_file.log,l_api_message);
546: end if;
547:
548: -- Check that required parameters are not null
549: if (P_ORG_ID is null OR P_TXN_ID is null OR P_USER_ID is null OR P_DBT_CRDT is null
617: where organization_id = P_ORG_ID;
618:
619: if (l_debug = 'Y') then
620: l_api_message := 'Got Set_Of_Books_ID = '||to_char(l_sob_id);
621: FND_FILE.PUT_LINE (fnd_file.log, l_api_message);
622: end if;
623:
624: -- Get primary currency
625: l_stmt_num := 80;
636: where currency_code = l_pri_curr;
637:
638: if (l_debug = 'Y') then
639: l_api_message := 'Got currency code = '||l_pri_curr;
640: FND_FILE.PUT_LINE (fnd_file.log,l_api_message);
641: end if;
642:
643: l_stmt_num := 100;
644: insert into mtl_transaction_accounts -- line 95
737: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
738: end if;
739:
740: if (l_debug = 'Y') then
741: FND_FILE.PUT_LINE (fnd_file.log,l_api_message);
742: end if;
743:
744: FND_MESSAGE.set_token('TEXT', l_api_message);
745: FND_MSG_PUB.ADD;
827:
828: FUNCTION get_log return number
829: IS
830: BEGIN
831: return fnd_file.log;
832: END get_log;
833:
834: -----------------------------------------------------------------------------
835: -- PROCEDURE --
905:
906: l_debug := FND_PROFILE.VALUE('MRP_DEBUG');
907:
908: /*if (l_debug = 'Y') then
909: fnd_file.put_line(fnd_file.log,'get_ZeroCostIssue_Flag');
910: end if;*/
911:
912: ------------------------------------------------
913: -- Standard call to check for API compatibility