DBA Data[Home] [Help]

APPS.MTL_CCEOI_PROCESS_PVT dependencies on FND_API

Line 138: if (l_return_status <> fnd_api.g_ret_sts_success) then

134:
135: IF (l_debug = 1) THEN
136: mdebug('Due date'||to_char(l_result_date));
137: END IF;
138: if (l_return_status <> fnd_api.g_ret_sts_success) then
139: IF (l_debug = 1) THEN
140: mdebug('error in due date computation');
141: END IF;
142: raise fnd_api.g_exc_unexpected_error;

Line 142: raise fnd_api.g_exc_unexpected_error;

138: if (l_return_status <> fnd_api.g_ret_sts_success) then
139: IF (l_debug = 1) THEN
140: mdebug('error in due date computation');
141: END IF;
142: raise fnd_api.g_exc_unexpected_error;
143: end if;
144:
145: return l_result_date;
146:

Line 474: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)

470: p_lot_expiration IN date ,
471: p_revision IN VARCHAR2 ,
472: p_transaction_reason_id IN NUMBER ,
473: p_transaction_process_mode IN NUMBER DEFAULT 3,
474: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)
475: IS
476: l_debug number := NVL(FND_PROFILE.VALUE('INV_DEBUG_TRACE'),0);
477: BEGIN
478: -- Start OF comments

Line 511: -- default = FND_API.G_FALSE may modify tables other than interface

507: -- default = 3 (Background processing) this parameter is not really used
508: -- since the only way the processing can be done now is in background mode
509: --
510: -- p_simulate IN VARCHAR2 (defaulted)
511: -- default = FND_API.G_FALSE may modify tables other than interface
512: -- FND_API.G_TRUE - may modify only interface tables
513: --
514: -- OUT :
515: -- Version: Current Version 0.9

Line 512: -- FND_API.G_TRUE - may modify only interface tables

508: -- since the only way the processing can be done now is in background mode
509: --
510: -- p_simulate IN VARCHAR2 (defaulted)
511: -- default = FND_API.G_FALSE may modify tables other than interface
512: -- FND_API.G_TRUE - may modify only interface tables
513: --
514: -- OUT :
515: -- Version: Current Version 0.9
516: -- Changed : Nothing

Line 587: AND NOT FND_API.to_Boolean(p_simulate)

583: END IF;
584:
585: IF MTL_CCEOI_VAR_PVT.G_CC_ENTRY_REC_TMP.entry_status_code = 5
586: AND MTL_CCEOI_VAR_PVT.G_ADJUSTMENT_QUANTITY <> 0
587: AND NOT FND_API.to_Boolean(p_simulate)
588: THEN
589: --
590: IF (l_debug = 1) THEN
591: MDEBUG( 'F-P-U-Inside the If value ');

Line 721: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)

717: p_revision VARCHAR2 ,
718: p_transaction_reason_id NUMBER ,
719: p_serial_number VARCHAR2 ,
720: p_transaction_process_mode NUMBER ,
721: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)
722: IS
723: l_debug number := NVL(FND_PROFILE.VALUE('INV_DEBUG_TRACE'),0);
724: BEGIN
725: -- Start OF comments

Line 754: -- p_simulate in varchar2 (defaulted FND_API.G_FALSE)

750: --
751: -- p_transaction_process_mode IN NUMBER (required-defaulted)
752: -- default = 3 (Background processing)
753: --
754: -- p_simulate in varchar2 (defaulted FND_API.G_FALSE)
755: -- G_FALSE - may modify data in tables other than ccoi interface
756: -- G_TRUE - may not modify data in tables othert than ccoi interface
757:
758: -- OUT :

Line 816: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)

812: p_revision VARCHAR2 ,
813: p_transaction_reason_id NUMBER ,
814: p_serial_number VARCHAR2 ,
815: p_transaction_process_mode NUMBER ,
816: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)
817: IS
818: l_debug number := NVL(FND_PROFILE.VALUE('INV_DEBUG_TRACE'),0);
819: BEGIN
820: -- Start OF comments

Line 849: -- p_simulate in varchar2 (defaulted FND_API.G_FALSE)

845: --
846: -- p_transaction_process_mode IN NUMBER (required-defaulted)
847: -- default = 3 (Background processing)
848: --
849: -- p_simulate in varchar2 (defaulted FND_API.G_FALSE)
850: -- G_FALSE - may modify data in tables other than cc interface
851: -- G_TRUE - may not modify data in tables other than cc interface
852: -- OUT :
853: -- Version: Current Version 0.9

Line 925: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)

921: p_adjustment_quantity IN NUMBER ,
922: p_system_quantity IN NUMBER ,
923: p_approval_option_code IN NUMBER ,
924: p_interface_rec IN MTL_CCEOI_VAR_PVT.INV_CCEOI_TYPE ,
925: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)
926: IS
927: l_debug number := NVL(FND_PROFILE.VALUE('INV_DEBUG_TRACE'),0);
928: BEGIN
929: -- Start OF comments

Line 973: -- default = FND_API.G_FALSE - may modify data in other tables

969: --
970: -- p_interface_rec IN MTL_CC_ENTRIES_INTERFACE%rowtype
971: --
972: -- p_simulate IN varchar2 (default)
973: -- default = FND_API.G_FALSE - may modify data in other tables
974: -- FND_API.G_TRUE modify data only in the interface tables
975: --
976: -- OUT :
977: -- Version: Current Version 0.9

Line 974: -- FND_API.G_TRUE modify data only in the interface tables

970: -- p_interface_rec IN MTL_CC_ENTRIES_INTERFACE%rowtype
971: --
972: -- p_simulate IN varchar2 (default)
973: -- default = FND_API.G_FALSE - may modify data in other tables
974: -- FND_API.G_TRUE modify data only in the interface tables
975: --
976: -- OUT :
977: -- Version: Current Version 0.9
978: -- Changed : Nothing

Line 1575: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,

1571: --
1572: -- Calculates adjustments for Step 4
1573: PROCEDURE Calculate_Adjustment(
1574: p_api_version IN NUMBER ,
1575: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
1576: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
1577: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
1578: x_return_status OUT NOCOPY VARCHAR2 ,
1579: x_msg_count OUT NOCOPY NUMBER ,

Line 1576: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,

1572: -- Calculates adjustments for Step 4
1573: PROCEDURE Calculate_Adjustment(
1574: p_api_version IN NUMBER ,
1575: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
1576: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
1577: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
1578: x_return_status OUT NOCOPY VARCHAR2 ,
1579: x_msg_count OUT NOCOPY NUMBER ,
1580: x_msg_data OUT NOCOPY VARCHAR2 ,

Line 1577: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,

1573: PROCEDURE Calculate_Adjustment(
1574: p_api_version IN NUMBER ,
1575: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
1576: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
1577: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
1578: x_return_status OUT NOCOPY VARCHAR2 ,
1579: x_msg_count OUT NOCOPY NUMBER ,
1580: x_msg_data OUT NOCOPY VARCHAR2 ,
1581: x_errorcode OUT NOCOPY NUMBER ,

Line 1620: -- DEFAULT = FND_API.G_FALSE,

1616: -- p_api_version IN NUMBER (required)
1617: -- API Version of this procedure
1618: --
1619: -- p_init_msg_list IN VARCHAR2 (optional)
1620: -- DEFAULT = FND_API.G_FALSE,
1621: --
1622: -- p_commit IN VARCHAR2 (optional)
1623: -- DEFAULT = FND_API.G_FALSE
1624: --

Line 1623: -- DEFAULT = FND_API.G_FALSE

1619: -- p_init_msg_list IN VARCHAR2 (optional)
1620: -- DEFAULT = FND_API.G_FALSE,
1621: --
1622: -- p_commit IN VARCHAR2 (optional)
1623: -- DEFAULT = FND_API.G_FALSE
1624: --
1625: -- p_validation_level IN NUMBER (optional)
1626: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
1627: --

Line 1626: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,

1622: -- p_commit IN VARCHAR2 (optional)
1623: -- DEFAULT = FND_API.G_FALSE
1624: --
1625: -- p_validation_level IN NUMBER (optional)
1626: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
1627: --
1628: -- p_inventory_item_id IN NUMBER (required)
1629: -- ID OF the inventory item
1630: --

Line 1700: IF NOT FND_API.Compatible_API_Call(l_api_version

1696: -- Standard start of API savepoint
1697: SAVEPOINT Calculate_Adjustment;
1698: --
1699: -- Standard Call to check for call compatibility
1700: IF NOT FND_API.Compatible_API_Call(l_api_version
1701: , p_api_version
1702: , l_api_name
1703: , G_PKG_NAME) THEN
1704: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 1704: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

1700: IF NOT FND_API.Compatible_API_Call(l_api_version
1701: , p_api_version
1702: , l_api_name
1703: , G_PKG_NAME) THEN
1704: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
1705: END IF;
1706: --
1707: -- Initialize message list if p_init_msg_list is set to true
1708: IF FND_API.to_Boolean(p_init_msg_list) THEN

Line 1708: IF FND_API.to_Boolean(p_init_msg_list) THEN

1704: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
1705: END IF;
1706: --
1707: -- Initialize message list if p_init_msg_list is set to true
1708: IF FND_API.to_Boolean(p_init_msg_list) THEN
1709: FND_MSG_PUB.initialize;
1710: END IF;
1711: --
1712: -- Initialisize API return status to access

Line 1713: x_return_status := FND_API.G_RET_STS_SUCCESS;

1709: FND_MSG_PUB.initialize;
1710: END IF;
1711: --
1712: -- Initialisize API return status to access
1713: x_return_status := FND_API.G_RET_STS_SUCCESS;
1714: x_errorcode := 0;
1715: MTL_CCEOI_VAR_PVT.G_SYSTEM_QUANTITY := 0;
1716: MTL_CCEOI_VAR_PVT.G_SECONDARY_SYSTEM_QUANTITY := 0; -- INVCONV
1717: --

Line 1781: , p_init_msg_lst => fnd_api.g_true

1777: -- Looking for a quanitity for an item withing a specific container.
1778: MTL_INV_UTIL_GRP.Get_LPN_Item_SysQty
1779: (
1780: p_api_version => 1.0
1781: , p_init_msg_lst => fnd_api.g_true
1782: , p_commit => fnd_api.g_true
1783: , x_return_status => x_return_status
1784: , x_msg_count => x_msg_count
1785: , x_msg_data => x_msg_data

Line 1782: , p_commit => fnd_api.g_true

1778: MTL_INV_UTIL_GRP.Get_LPN_Item_SysQty
1779: (
1780: p_api_version => 1.0
1781: , p_init_msg_lst => fnd_api.g_true
1782: , p_commit => fnd_api.g_true
1783: , x_return_status => x_return_status
1784: , x_msg_count => x_msg_count
1785: , x_msg_data => x_msg_data
1786: , p_organization_id => p_organization_id

Line 1991: RAISE FND_API.G_EXC_ERROR;

1987: --
1988: x_errorcode := 17;
1989: FND_MESSAGE.SET_NAME('INV', 'INV_CCEOI_ADJCALC_NO_SERIAL');
1990: FND_MSG_PUB.Add;
1991: RAISE FND_API.G_EXC_ERROR;
1992: --
1993: END IF;
1994: */
1995: --

Line 1999: IF FND_API.to_Boolean(p_commit) THEN

1995: --
1996: --
1997: -- END of API body
1998: -- Standard check of p_commit
1999: IF FND_API.to_Boolean(p_commit) THEN
2000: COMMIT;
2001: END IF;
2002: -- Standard call to get message count and if count is 1, get message info
2003: FND_MSG_PUB.Count_And_Get

Line 2007: WHEN FND_API.G_EXC_ERROR THEN

2003: FND_MSG_PUB.Count_And_Get
2004: (p_count => x_msg_count
2005: , p_data => x_msg_data);
2006: EXCEPTION
2007: WHEN FND_API.G_EXC_ERROR THEN
2008: --
2009: ROLLBACK TO Calculate_Adjustment;
2010: --
2011: x_return_status := FND_API.G_RET_STS_ERROR;

Line 2011: x_return_status := FND_API.G_RET_STS_ERROR;

2007: WHEN FND_API.G_EXC_ERROR THEN
2008: --
2009: ROLLBACK TO Calculate_Adjustment;
2010: --
2011: x_return_status := FND_API.G_RET_STS_ERROR;
2012: --
2013: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
2014: , p_data => x_msg_data);
2015: --

Line 2016: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

2012: --
2013: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
2014: , p_data => x_msg_data);
2015: --
2016: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
2017: --
2018: ROLLBACK TO Calculate_Adjustment;
2019: --
2020: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 2020: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

2016: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
2017: --
2018: ROLLBACK TO Calculate_Adjustment;
2019: --
2020: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2021: --
2022: x_errorcode := -1;
2023: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
2024: , p_data => x_msg_data);

Line 2031: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

2027: --
2028: ROLLBACK TO Calculate_Adjustment;
2029: --
2030: x_errorcode := -1;
2031: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2032: --
2033: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
2034: FND_MSG_PUB.Add_Exc_Msg(G_PKG_NAME, l_api_name);
2035: END IF;

Line 2055: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)

2051: p_head_app_tol_neg IN NUMBER ,
2052: p_head_cost_tol_pos IN NUMBER ,
2053: p_head_cost_tol_neg IN NUMBER ,
2054: p_interface_rec IN MTL_CCEOI_VAR_PVT.INV_CCEOI_TYPE ,
2055: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)
2056: IS
2057: l_debug number := NVL(FND_PROFILE.VALUE('INV_DEBUG_TRACE'),0);
2058: BEGIN
2059: -- Start OF comments

Line 2102: -- p_simulate NUMBER (default = FND_API.G_FALSE)

2098: --
2099: -- p_head_cost_tol_neg IN NUMBER (required)
2100: -- MTL_CYCLE_COUNT_HEADERS.COST_TOLERANCE_NEGATIVE
2101: --
2102: -- p_simulate NUMBER (default = FND_API.G_FALSE)
2103: -- G_FALSE = allow changes to tables other than interface tables
2104: -- G_TRUE = no changes will be made to any outside tables
2105: -- OUT :
2106: --

Line 2547: raise fnd_api.g_exc_unexpected_error;

2543: IF (l_debug = 1) THEN
2544: MDEBUG( 'Exception Error while Inserting..');
2545: MDEBUG( 'Error: ' || sqlerrm);
2546: END IF;
2547: raise fnd_api.g_exc_unexpected_error;
2548: END;
2549: END;
2550: --
2551: -- Insert the given record into MTL_CC_ENTRIES_INTERFACE

Line 2579: X_return_status := FND_API.G_RET_STS_SUCCESS;

2575: IF (l_debug = 1) THEN
2576: MDEBUG( 'Insert_CCIEntry: Before creation of new seq id');
2577: END IF;
2578:
2579: X_return_status := FND_API.G_RET_STS_SUCCESS;
2580: --
2581:
2582: IF p_interface_rec.cc_entry_interface_id IS NULL THEN
2583: BEGIN

Line 2595: X_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

2591: WHEN OTHERS THEN
2592: IF (l_debug = 1) THEN
2593: mdebug('id creation failed failed');
2594: END IF;
2595: X_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2596: END;
2597: END IF;
2598: --
2599: BEGIN

Line 2900: x_return_status := fnd_api.g_ret_sts_error;

2896: MTL_CCEOI_VAR_PVT.G_REC_IN_SYSTEM := TRUE;
2897: EXCEPTION
2898: WHEN OTHERS THEN
2899: if p_interface_rec.organization_id is null then
2900: x_return_status := fnd_api.g_ret_sts_error;
2901: else
2902: X_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2903: end if;
2904: IF (l_debug = 1) THEN

Line 2902: X_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

2898: WHEN OTHERS THEN
2899: if p_interface_rec.organization_id is null then
2900: x_return_status := fnd_api.g_ret_sts_error;
2901: else
2902: X_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
2903: end if;
2904: IF (l_debug = 1) THEN
2905: mdebug('Insert_CCIEntry: ' || sqlerrm);
2906: END IF;

Line 3012: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)

3008: p_lot_expiration IN date ,
3009: p_revision IN VARCHAR2 ,
3010: p_transaction_reason_id IN NUMBER ,
3011: p_transaction_process_mode IN NUMBER DEFAULT 3,
3012: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE)
3013: IS
3014: l_debug number := NVL(FND_PROFILE.VALUE('INV_DEBUG_TRACE'),0);
3015: BEGIN
3016: -- Start OF comments

Line 3046: -- default = FND_API.G_FALSE - may update data in any tables

3042: -- p_transaction_process_mode IN NUMBER (required-defaulted)
3043: -- default = 3 (Background processing)
3044: --
3045: -- p_simulate IN VARCHAR2 (defaulted)
3046: -- default = FND_API.G_FALSE - may update data in any tables
3047: -- FND_API.G_TRUE - may only update data in the interface tables
3048: -- OUT :
3049: -- Version: Current Version 0.9
3050: -- Changed : Nothing

Line 3047: -- FND_API.G_TRUE - may only update data in the interface tables

3043: -- default = 3 (Background processing)
3044: --
3045: -- p_simulate IN VARCHAR2 (defaulted)
3046: -- default = FND_API.G_FALSE - may update data in any tables
3047: -- FND_API.G_TRUE - may only update data in the interface tables
3048: -- OUT :
3049: -- Version: Current Version 0.9
3050: -- Changed : Nothing
3051: -- No Previous Version 0.0

Line 3159: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3155: --
3156: -- Set the export flag in the table MTL_CYCLE_COUNT_ENTRIES
3157: PROCEDURE Set_CCExport(
3158: p_api_version IN NUMBER ,
3159: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3160: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3161: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3162: x_return_status OUT NOCOPY VARCHAR2 ,
3163: x_msg_count OUT NOCOPY NUMBER ,

Line 3160: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3156: -- Set the export flag in the table MTL_CYCLE_COUNT_ENTRIES
3157: PROCEDURE Set_CCExport(
3158: p_api_version IN NUMBER ,
3159: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3160: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3161: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3162: x_return_status OUT NOCOPY VARCHAR2 ,
3163: x_msg_count OUT NOCOPY NUMBER ,
3164: x_msg_data OUT NOCOPY VARCHAR2 ,

Line 3161: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,

3157: PROCEDURE Set_CCExport(
3158: p_api_version IN NUMBER ,
3159: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3160: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3161: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3162: x_return_status OUT NOCOPY VARCHAR2 ,
3163: x_msg_count OUT NOCOPY NUMBER ,
3164: x_msg_data OUT NOCOPY VARCHAR2 ,
3165: p_cycle_count_entry_id IN NUMBER ,

Line 3182: -- DEFAULT = FND_API.G_FALSE,

3178: -- p_api_version IN NUMBER (required)
3179: -- API Version of this procedure
3180: --
3181: -- p_init_msg_list IN VARCHAR2 (optional)
3182: -- DEFAULT = FND_API.G_FALSE,
3183: --
3184: -- p_commit IN VARCHAR2 (optional)
3185: -- DEFAULT = FND_API.G_FALSE,
3186: --

Line 3185: -- DEFAULT = FND_API.G_FALSE,

3181: -- p_init_msg_list IN VARCHAR2 (optional)
3182: -- DEFAULT = FND_API.G_FALSE,
3183: --
3184: -- p_commit IN VARCHAR2 (optional)
3185: -- DEFAULT = FND_API.G_FALSE,
3186: --
3187: -- p_validation_level IN NUMBER (optional)
3188: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3189: --

Line 3188: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,

3184: -- p_commit IN VARCHAR2 (optional)
3185: -- DEFAULT = FND_API.G_FALSE,
3186: --
3187: -- p_validation_level IN NUMBER (optional)
3188: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3189: --
3190: -- p_cycle_count_entry_id IN NUMBER (required)
3191: -- cycle COUNT entry id
3192: --

Line 3221: IF NOT FND_API.Compatible_API_Call(

3217: -- Standard Call to check for call compatibility
3218: IF (l_debug = 1) THEN
3219: MDEBUG( 'SetCCExport : Before API');
3220: END IF;
3221: IF NOT FND_API.Compatible_API_Call(
3222: l_api_version, p_api_version
3223: , l_api_name
3224: , G_PKG_NAME) THEN
3225: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 3225: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

3221: IF NOT FND_API.Compatible_API_Call(
3222: l_api_version, p_api_version
3223: , l_api_name
3224: , G_PKG_NAME) THEN
3225: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
3226: END IF;
3227: IF (l_debug = 1) THEN
3228: MDEBUG( 'SetCCExport : After API');
3229: END IF;

Line 3232: IF FND_API.to_Boolean(p_init_msg_list) THEN

3228: MDEBUG( 'SetCCExport : After API');
3229: END IF;
3230: --
3231: -- Initialize message list if p_init_msg_list is set to true
3232: IF FND_API.to_Boolean(p_init_msg_list) THEN
3233: FND_MSG_PUB.initialize;
3234: END IF;
3235: --
3236: IF (l_debug = 1) THEN

Line 3240: x_return_status := FND_API.G_RET_STS_SUCCESS;

3236: IF (l_debug = 1) THEN
3237: MDEBUG( 'SetCCExport : After Init');
3238: END IF;
3239: -- Initialisize API return status to access
3240: x_return_status := FND_API.G_RET_STS_SUCCESS;
3241: --
3242: -- API body
3243: --
3244: IF (l_debug = 1) THEN

Line 3270: RAISE FND_API.G_EXC_ERROR;

3266: MDEBUG( 'SetCCExport : Error Update');
3267: END IF;
3268: FND_MESSAGE.SET_NAME('INV', 'INV_CCEOI_COULD_NOT_LOCK');
3269: FND_MSG_PUB.Add;
3270: RAISE FND_API.G_EXC_ERROR;
3271: END IF;
3272: --
3273: -- END of API body
3274: -- Standard check of p_commit

Line 3275: IF FND_API.to_Boolean(p_commit) THEN

3271: END IF;
3272: --
3273: -- END of API body
3274: -- Standard check of p_commit
3275: IF FND_API.to_Boolean(p_commit) THEN
3276: COMMIT;
3277: END IF;
3278: -- --
3279: -- Standard call to get message count and if count is 1, get message info

Line 3284: WHEN FND_API.G_EXC_ERROR THEN

3280: FND_MSG_PUB.Count_And_Get
3281: (p_count => x_msg_count
3282: , p_data => x_msg_data);
3283: EXCEPTION
3284: WHEN FND_API.G_EXC_ERROR THEN
3285: --
3286: ROLLBACK TO Set_CCExport;
3287: --
3288: x_return_status := FND_API.G_RET_STS_ERROR;

Line 3288: x_return_status := FND_API.G_RET_STS_ERROR;

3284: WHEN FND_API.G_EXC_ERROR THEN
3285: --
3286: ROLLBACK TO Set_CCExport;
3287: --
3288: x_return_status := FND_API.G_RET_STS_ERROR;
3289: --
3290: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3291: , p_data => x_msg_data);
3292: --

Line 3293: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

3289: --
3290: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3291: , p_data => x_msg_data);
3292: --
3293: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
3294: --
3295: ROLLBACK TO Set_CCExport;
3296: --
3297: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 3297: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

3293: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
3294: --
3295: ROLLBACK TO Set_CCExport;
3296: --
3297: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3298: --
3299: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3300: , p_data => x_msg_data);
3301: --

Line 3306: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

3302: WHEN OTHERS THEN
3303: --
3304: ROLLBACK TO Set_CCExport;
3305: --
3306: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3307: --
3308: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
3309: FND_MSG_PUB.Add_Exc_Msg(G_PKG_NAME, l_api_name);
3310: END IF;

Line 3320: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3316: --
3317: -- Set the Flags in the interface table.
3318: PROCEDURE Set_CCEOIFlags(
3319: p_api_version IN NUMBER ,
3320: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3321: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3322: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3323: x_return_status OUT NOCOPY VARCHAR2 ,
3324: x_msg_count OUT NOCOPY NUMBER ,

Line 3321: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3317: -- Set the Flags in the interface table.
3318: PROCEDURE Set_CCEOIFlags(
3319: p_api_version IN NUMBER ,
3320: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3321: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3322: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3323: x_return_status OUT NOCOPY VARCHAR2 ,
3324: x_msg_count OUT NOCOPY NUMBER ,
3325: x_msg_data OUT NOCOPY VARCHAR2 ,

Line 3322: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,

3318: PROCEDURE Set_CCEOIFlags(
3319: p_api_version IN NUMBER ,
3320: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3321: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3322: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3323: x_return_status OUT NOCOPY VARCHAR2 ,
3324: x_msg_count OUT NOCOPY NUMBER ,
3325: x_msg_data OUT NOCOPY VARCHAR2 ,
3326: p_cc_entry_interface_id IN NUMBER ,

Line 3344: -- DEFAULT = FND_API.G_FALSE,

3340: -- p_api_version IN NUMBER (required)
3341: -- API Version of this procedure
3342: --
3343: -- p_init_msg_list IN VARCHAR2 (optional)
3344: -- DEFAULT = FND_API.G_FALSE,
3345: --
3346: -- p_commit IN VARCHAR2 (optional)
3347: -- DEFAULT = FND_API.G_FALSE,
3348: --

Line 3347: -- DEFAULT = FND_API.G_FALSE,

3343: -- p_init_msg_list IN VARCHAR2 (optional)
3344: -- DEFAULT = FND_API.G_FALSE,
3345: --
3346: -- p_commit IN VARCHAR2 (optional)
3347: -- DEFAULT = FND_API.G_FALSE,
3348: --
3349: -- p_validation_level IN NUMBER (optional)
3350: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3351: --

Line 3350: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,

3346: -- p_commit IN VARCHAR2 (optional)
3347: -- DEFAULT = FND_API.G_FALSE,
3348: --
3349: -- p_validation_level IN NUMBER (optional)
3350: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3351: --
3352: -- p_cc_entry_interface_id IN NUMBER (required)
3353: -- cycle COUNT entry interface id
3354: --

Line 3389: IF NOT FND_API.Compatible_API_Call(

3385: -- Standard start of API savepoint
3386: SAVEPOINT SET_CCEOIVALID;
3387: --
3388: -- Standard Call to check for call compatibility
3389: IF NOT FND_API.Compatible_API_Call(
3390: l_api_version, p_api_version
3391: , l_api_name
3392: , G_PKG_NAME) THEN
3393: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 3393: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

3389: IF NOT FND_API.Compatible_API_Call(
3390: l_api_version, p_api_version
3391: , l_api_name
3392: , G_PKG_NAME) THEN
3393: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
3394: END IF;
3395:
3396: --
3397: -- Initialize message list if p_init_msg_list is set to true

Line 3398: IF FND_API.to_Boolean(p_init_msg_list) THEN

3394: END IF;
3395:
3396: --
3397: -- Initialize message list if p_init_msg_list is set to true
3398: IF FND_API.to_Boolean(p_init_msg_list) THEN
3399: FND_MSG_PUB.initialize;
3400: END IF;
3401:
3402: --

Line 3404: x_return_status := FND_API.G_RET_STS_SUCCESS;

3400: END IF;
3401:
3402: --
3403: -- Initialisize API return status to access
3404: x_return_status := FND_API.G_RET_STS_SUCCESS;
3405: --
3406: -- API body
3407: --
3408: -- UPDATE the flags according to the parameter

Line 3438: RAISE FND_API.G_EXC_ERROR;

3434: --
3435: IF SQL%ROWCOUNT <> 1 THEN
3436: FND_MESSAGE.SET_NAME('INV', 'INV_CCEOI_COULD_NOT_LOCK');
3437: FND_MSG_PUB.Add;
3438: RAISE FND_API.G_EXC_ERROR;
3439: END IF;
3440: --
3441: -- END of API body
3442: -- Standard check of p_commit

Line 3443: IF FND_API.to_Boolean(p_commit) THEN

3439: END IF;
3440: --
3441: -- END of API body
3442: -- Standard check of p_commit
3443: IF FND_API.to_Boolean(p_commit) THEN
3444: COMMIT;
3445: END IF;
3446: -- --
3447: -- Standard call to get message count and if count is 1, get message info

Line 3452: WHEN FND_API.G_EXC_ERROR THEN

3448: FND_MSG_PUB.Count_And_Get
3449: (p_count => x_msg_count
3450: , p_data => x_msg_data);
3451: EXCEPTION
3452: WHEN FND_API.G_EXC_ERROR THEN
3453: --
3454: IF (l_debug = 1) THEN
3455: mdebug('Error in Set_CCEOIFlags');
3456: END IF;

Line 3459: x_return_status := FND_API.G_RET_STS_ERROR;

3455: mdebug('Error in Set_CCEOIFlags');
3456: END IF;
3457: ROLLBACK TO Set_CCEOIValid;
3458: --
3459: x_return_status := FND_API.G_RET_STS_ERROR;
3460: --
3461: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3462: , p_data => x_msg_data);
3463: --

Line 3464: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

3460: --
3461: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3462: , p_data => x_msg_data);
3463: --
3464: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
3465: --
3466: IF (l_debug = 1) THEN
3467: mdebug('Unexpected Error in Set_CCEOIFlags');
3468: END IF;

Line 3471: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

3467: mdebug('Unexpected Error in Set_CCEOIFlags');
3468: END IF;
3469: ROLLBACK TO Set_CCEOIValid;
3470: --
3471: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3472: --
3473: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3474: , p_data => x_msg_data);
3475: --

Line 3486: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

3482: IF (l_debug = 1) THEN
3483: mdebug('After Rollback for Other Error in Set_CCEOIFlags');
3484: END IF;
3485: --
3486: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3487: --
3488: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
3489: FND_MSG_PUB.Add_Exc_Msg(G_PKG_NAME, l_api_name);
3490: END IF;

Line 3500: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3496: --
3497: -- Validates the cycle count header
3498: PROCEDURE Validate_CHeader(
3499: p_api_version IN NUMBER ,
3500: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3501: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3502: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3503: x_return_status OUT NOCOPY VARCHAR2 ,
3504: x_msg_count OUT NOCOPY NUMBER ,

Line 3501: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3497: -- Validates the cycle count header
3498: PROCEDURE Validate_CHeader(
3499: p_api_version IN NUMBER ,
3500: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3501: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3502: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3503: x_return_status OUT NOCOPY VARCHAR2 ,
3504: x_msg_count OUT NOCOPY NUMBER ,
3505: x_msg_data OUT NOCOPY VARCHAR2 ,

Line 3502: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,

3498: PROCEDURE Validate_CHeader(
3499: p_api_version IN NUMBER ,
3500: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3501: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3502: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3503: x_return_status OUT NOCOPY VARCHAR2 ,
3504: x_msg_count OUT NOCOPY NUMBER ,
3505: x_msg_data OUT NOCOPY VARCHAR2 ,
3506: x_errorcode OUT NOCOPY NUMBER ,

Line 3524: -- DEFAULT = FND_API.G_FALSE,

3520: -- p_api_version IN NUMBER (required)
3521: -- API Version of this procedure
3522: --
3523: -- p_init_msg_list IN VARCHAR2 (optional)
3524: -- DEFAULT = FND_API.G_FALSE,
3525: --
3526: -- p_commit IN VARCHAR2 (optional)
3527: -- DEFAULT = FND_API.G_FALSE
3528: --

Line 3527: -- DEFAULT = FND_API.G_FALSE

3523: -- p_init_msg_list IN VARCHAR2 (optional)
3524: -- DEFAULT = FND_API.G_FALSE,
3525: --
3526: -- p_commit IN VARCHAR2 (optional)
3527: -- DEFAULT = FND_API.G_FALSE
3528: --
3529: -- p_validation_level IN NUMBER (optional)
3530: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3531: --

Line 3530: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,

3526: -- p_commit IN VARCHAR2 (optional)
3527: -- DEFAULT = FND_API.G_FALSE
3528: --
3529: -- p_validation_level IN NUMBER (optional)
3530: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3531: --
3532: -- p_cycle_count_header_id IN NUMBER default NULL (required - defaulted NULL)
3533: -- Cycle COUNT header ID
3534: --

Line 3563: IF NOT FND_API.Compatible_API_Call(l_api_version

3559: -- Standard start of API savepoint
3560: SAVEPOINT Validate_CHeader;
3561: --
3562: -- Standard Call to check for call compatibility
3563: IF NOT FND_API.Compatible_API_Call(l_api_version
3564: , p_api_version
3565: , l_api_name
3566: , G_PKG_NAME) THEN
3567: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 3567: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

3563: IF NOT FND_API.Compatible_API_Call(l_api_version
3564: , p_api_version
3565: , l_api_name
3566: , G_PKG_NAME) THEN
3567: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
3568: END IF;
3569: --
3570: -- Initialize message list if p_init_msg_list is set to true
3571: IF FND_API.to_Boolean(p_init_msg_list) THEN

Line 3571: IF FND_API.to_Boolean(p_init_msg_list) THEN

3567: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
3568: END IF;
3569: --
3570: -- Initialize message list if p_init_msg_list is set to true
3571: IF FND_API.to_Boolean(p_init_msg_list) THEN
3572: FND_MSG_PUB.initialize;
3573: END IF;
3574: --
3575: -- Initialisize API return status to access

Line 3576: x_return_status := FND_API.G_RET_STS_SUCCESS;

3572: FND_MSG_PUB.initialize;
3573: END IF;
3574: --
3575: -- Initialisize API return status to access
3576: x_return_status := FND_API.G_RET_STS_SUCCESS;
3577: --
3578: -- API body
3579: IF (l_debug = 1) THEN
3580: mdebug('Process: In Validate_CHeader ' || to_char(p_cycle_count_header_id));

Line 3638: IF FND_API.to_Boolean(p_commit) THEN

3634: END IF;
3635: --
3636: -- END of API body
3637: -- Standard check of p_commit
3638: IF FND_API.to_Boolean(p_commit) THEN
3639: COMMIT;
3640: END IF;
3641: -- Standard call to get message count and if count is 1, get message info
3642: FND_MSG_PUB.Count_And_Get

Line 3646: WHEN FND_API.G_EXC_ERROR THEN

3642: FND_MSG_PUB.Count_And_Get
3643: (p_count => x_msg_count
3644: , p_data => x_msg_data);
3645: EXCEPTION
3646: WHEN FND_API.G_EXC_ERROR THEN
3647: --
3648: --
3649: x_return_status := FND_API.G_RET_STS_ERROR;
3650: --

Line 3649: x_return_status := FND_API.G_RET_STS_ERROR;

3645: EXCEPTION
3646: WHEN FND_API.G_EXC_ERROR THEN
3647: --
3648: --
3649: x_return_status := FND_API.G_RET_STS_ERROR;
3650: --
3651: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3652: , p_data => x_msg_data);
3653: --

Line 3654: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

3650: --
3651: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3652: , p_data => x_msg_data);
3653: --
3654: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
3655: --
3656: --
3657: x_errorcode := -1;
3658: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 3658: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

3654: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
3655: --
3656: --
3657: x_errorcode := -1;
3658: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3659: --
3660: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3661: , p_data => x_msg_data);
3662: --

Line 3667: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

3663: WHEN OTHERS THEN
3664: --
3665: --
3666: x_errorcode := -1;
3667: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3668: --
3669: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
3670: FND_MSG_PUB.Add_Exc_Msg(G_PKG_NAME, l_api_name);
3671: END IF;

Line 3681: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3677: --
3678: -- Validate the count list sequence of the cycle count entry
3679: PROCEDURE Validate_CountListSeq(
3680: p_api_version IN NUMBER ,
3681: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3682: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3683: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3684: x_return_status OUT NOCOPY VARCHAR2 ,
3685: x_msg_count OUT NOCOPY NUMBER ,

Line 3682: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3678: -- Validate the count list sequence of the cycle count entry
3679: PROCEDURE Validate_CountListSeq(
3680: p_api_version IN NUMBER ,
3681: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3682: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3683: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3684: x_return_status OUT NOCOPY VARCHAR2 ,
3685: x_msg_count OUT NOCOPY NUMBER ,
3686: x_msg_data OUT NOCOPY VARCHAR2 ,

Line 3683: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,

3679: PROCEDURE Validate_CountListSeq(
3680: p_api_version IN NUMBER ,
3681: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3682: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3683: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3684: x_return_status OUT NOCOPY VARCHAR2 ,
3685: x_msg_count OUT NOCOPY NUMBER ,
3686: x_msg_data OUT NOCOPY VARCHAR2 ,
3687: x_errorcode OUT NOCOPY NUMBER ,

Line 3708: -- DEFAULT = FND_API.G_FALSE,

3704: -- p_api_version IN NUMBER (required)
3705: -- API Version of this procedure
3706: --
3707: -- p_init_msg_list IN VARCHAR2 (optional)
3708: -- DEFAULT = FND_API.G_FALSE,
3709: --
3710: -- p_commit IN VARCHAR2 (optional)
3711: -- DEFAULT = FND_API.G_FALSE
3712: --

Line 3711: -- DEFAULT = FND_API.G_FALSE

3707: -- p_init_msg_list IN VARCHAR2 (optional)
3708: -- DEFAULT = FND_API.G_FALSE,
3709: --
3710: -- p_commit IN VARCHAR2 (optional)
3711: -- DEFAULT = FND_API.G_FALSE
3712: --
3713: -- p_validation_level IN NUMBER (optional)
3714: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3715: -- 0 = FOR Export validation

Line 3714: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,

3710: -- p_commit IN VARCHAR2 (optional)
3711: -- DEFAULT = FND_API.G_FALSE
3712: --
3713: -- p_validation_level IN NUMBER (optional)
3714: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3715: -- 0 = FOR Export validation
3716: --
3717: -- p_cycle_count_header_id IN NUMBER (required -)
3718: -- Cycle COUNT header ID

Line 3749: IF NOT FND_API.Compatible_API_Call(l_api_version

3745: -- Standard start of API savepoint
3746: SAVEPOINT Validate_CountListSeq;
3747: --
3748: -- Standard Call to check for call compatibility
3749: IF NOT FND_API.Compatible_API_Call(l_api_version
3750: , p_api_version
3751: , l_api_name
3752: , G_PKG_NAME) THEN
3753: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 3753: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

3749: IF NOT FND_API.Compatible_API_Call(l_api_version
3750: , p_api_version
3751: , l_api_name
3752: , G_PKG_NAME) THEN
3753: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
3754: END IF;
3755: --
3756: -- Initialize message list if p_init_msg_list is set to true
3757: IF FND_API.to_Boolean(p_init_msg_list) THEN

Line 3757: IF FND_API.to_Boolean(p_init_msg_list) THEN

3753: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
3754: END IF;
3755: --
3756: -- Initialize message list if p_init_msg_list is set to true
3757: IF FND_API.to_Boolean(p_init_msg_list) THEN
3758: FND_MSG_PUB.initialize;
3759: END IF;
3760: --
3761: -- Initialisize API return status to access

Line 3762: x_return_status := FND_API.G_RET_STS_SUCCESS;

3758: FND_MSG_PUB.initialize;
3759: END IF;
3760: --
3761: -- Initialisize API return status to access
3762: x_return_status := FND_API.G_RET_STS_SUCCESS;
3763: --
3764: -- API body
3765: --
3766: IF (l_debug = 1) THEN

Line 3792: RAISE FND_API.G_EXC_ERROR;

3788: , p_error_column_name => 'CYCLE_COUNT_HEADER_ID'
3789: , p_error_table_name => 'MTL_CYCLE_COUNT_HEADERS'
3790: , p_message_name => 'INV_CCEOI_UNMATCH_LISTSEQ'
3791: );
3792: RAISE FND_API.G_EXC_ERROR;
3793: ELSIF x_errorcode in (65,66) THEN
3794: IF (l_debug = 1) THEN
3795: MDEBUG( 'Validate Seq for Unsch.'||to_char(x_errorcode));
3796: END IF;

Line 3809: RAISE FND_API.G_EXC_ERROR;

3805: , p_error_column_name => 'CYCLE_COUNT_HEADER_ID'
3806: , p_error_table_name => 'MTL_CYCLE_COUNT_HEADERS'
3807: , p_message_name => 'INV_CCEOI_MULT_MATCH_REQ'
3808: );
3809: RAISE FND_API.G_EXC_ERROR;
3810: ELSIF
3811: x_errorcode = 0 THEN
3812: IF (l_debug = 1) THEN
3813: mdebug('Process: In Validate_CountListSequence Derive ItemSKU');

Line 3823: IF FND_API.to_Boolean(p_commit) THEN

3819: --
3820: --
3821: -- END of API body
3822: -- Standard check of p_commit
3823: IF FND_API.to_Boolean(p_commit) THEN
3824: COMMIT;
3825: END IF;
3826: -- Standard call to get message count and if count is 1, get message info
3827: FND_MSG_PUB.Count_And_Get

Line 3831: WHEN FND_API.G_EXC_ERROR THEN

3827: FND_MSG_PUB.Count_And_Get
3828: (p_count => x_msg_count
3829: , p_data => x_msg_data);
3830: EXCEPTION
3831: WHEN FND_API.G_EXC_ERROR THEN
3832: --
3833: --
3834: x_return_status := FND_API.G_RET_STS_ERROR;
3835: --

Line 3834: x_return_status := FND_API.G_RET_STS_ERROR;

3830: EXCEPTION
3831: WHEN FND_API.G_EXC_ERROR THEN
3832: --
3833: --
3834: x_return_status := FND_API.G_RET_STS_ERROR;
3835: --
3836: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3837: , p_data => x_msg_data);
3838: --

Line 3839: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

3835: --
3836: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3837: , p_data => x_msg_data);
3838: --
3839: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
3840: --
3841: --
3842: x_errorcode := -1;
3843: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 3843: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

3839: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
3840: --
3841: --
3842: x_errorcode := -1;
3843: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3844: --
3845: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
3846: , p_data => x_msg_data);
3847: --

Line 3852: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

3848: WHEN OTHERS THEN
3849: --
3850: --
3851: x_errorcode := -1;
3852: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3853: --
3854: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
3855: FND_MSG_PUB.Add_Exc_Msg(G_PKG_NAME, l_api_name);
3856: END IF;

Line 3866: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3862: --
3863: -- validate item and sku information
3864: PROCEDURE Validate_ItemSKU(
3865: p_api_version IN NUMBER ,
3866: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3867: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3868: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3869: x_return_status OUT NOCOPY VARCHAR2 ,
3870: x_msg_count OUT NOCOPY NUMBER ,

Line 3867: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,

3863: -- validate item and sku information
3864: PROCEDURE Validate_ItemSKU(
3865: p_api_version IN NUMBER ,
3866: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3867: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3868: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3869: x_return_status OUT NOCOPY VARCHAR2 ,
3870: x_msg_count OUT NOCOPY NUMBER ,
3871: x_msg_data OUT NOCOPY VARCHAR2 ,

Line 3868: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,

3864: PROCEDURE Validate_ItemSKU(
3865: p_api_version IN NUMBER ,
3866: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3867: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
3868: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
3869: x_return_status OUT NOCOPY VARCHAR2 ,
3870: x_msg_count OUT NOCOPY NUMBER ,
3871: x_msg_data OUT NOCOPY VARCHAR2 ,
3872: x_errorcode OUT NOCOPY NUMBER ,

Line 3879: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE )

3875: p_sku_rec IN MTL_CCEOI_VAR_PVT.Inv_SKU_Rec_Type ,
3876: p_subinventory IN VARCHAR2 ,
3877: p_locator_rec IN MTL_CCEOI_VAR_PVT.INV_LOCATOR_REC_TYPE ,
3878: p_organization_id IN number,
3879: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE )
3880: IS
3881: l_debug number := NVL(FND_PROFILE.VALUE('INV_DEBUG_TRACE'),0);
3882: BEGIN
3883: -- Start OF comments

Line 3895: -- DEFAULT = FND_API.G_FALSE,

3891: -- p_api_version IN NUMBER (required)
3892: -- API Version of this procedure
3893: --
3894: -- p_init_msg_list IN VARCHAR2 (optional)
3895: -- DEFAULT = FND_API.G_FALSE,
3896: --
3897: -- p_commit IN VARCHAR2 (optional)
3898: -- DEFAULT = FND_API.G_FALSE
3899: --

Line 3898: -- DEFAULT = FND_API.G_FALSE

3894: -- p_init_msg_list IN VARCHAR2 (optional)
3895: -- DEFAULT = FND_API.G_FALSE,
3896: --
3897: -- p_commit IN VARCHAR2 (optional)
3898: -- DEFAULT = FND_API.G_FALSE
3899: --
3900: -- p_validation_level IN NUMBER (optional)
3901: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3902: --

Line 3901: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,

3897: -- p_commit IN VARCHAR2 (optional)
3898: -- DEFAULT = FND_API.G_FALSE
3899: --
3900: -- p_validation_level IN NUMBER (optional)
3901: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
3902: --
3903: -- p_cycle_count_header_id IN NUMBER (required)
3904: -- Cycle COUNT header id
3905: --

Line 3991: IF NOT FND_API.Compatible_API_Call(l_api_version

3987: -- Standard start of API savepoint
3988: SAVEPOINT Validate_ItemSKU;
3989: --
3990: -- Standard Call to check for call compatibility
3991: IF NOT FND_API.Compatible_API_Call(l_api_version
3992: , p_api_version
3993: , l_api_name
3994: , G_PKG_NAME) THEN
3995: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 3995: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

3991: IF NOT FND_API.Compatible_API_Call(l_api_version
3992: , p_api_version
3993: , l_api_name
3994: , G_PKG_NAME) THEN
3995: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
3996: END IF;
3997: --
3998: -- Initialize message list if p_init_msg_list is set to true
3999: IF FND_API.to_Boolean(p_init_msg_list) THEN

Line 3999: IF FND_API.to_Boolean(p_init_msg_list) THEN

3995: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
3996: END IF;
3997: --
3998: -- Initialize message list if p_init_msg_list is set to true
3999: IF FND_API.to_Boolean(p_init_msg_list) THEN
4000: FND_MSG_PUB.initialize;
4001: END IF;
4002: --
4003: -- Initialisize API return status to access

Line 4004: x_return_status := FND_API.G_RET_STS_SUCCESS;

4000: FND_MSG_PUB.initialize;
4001: END IF;
4002: --
4003: -- Initialisize API return status to access
4004: x_return_status := FND_API.G_RET_STS_SUCCESS;
4005: --
4006: -- API body
4007: IF (l_debug = 1) THEN
4008: mdebug('Process: In Validate_ItemSKU');

Line 4048: RAISE FND_API.G_EXC_ERROR;

4044: , p_error_table_name => L_table_name
4045: , p_message_name => L_message_name
4046: );
4047: --
4048: RAISE FND_API.G_EXC_ERROR;
4049: ELSIF
4050: x_errorcode < 0 THEN
4051: -- Write INTO interface error TABLE
4052: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(

Line 4058: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4054: , p_error_column_name => 'unexpected error'
4055: , p_error_table_name => 'unexpected error'
4056: , p_message_name => 'unexpected error'
4057: );
4058: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4059: END IF;
4060: --
4061: IF (l_debug = 1) THEN
4062: mdebug('Process: In Validate_ItemSKU call Subinv ');

Line 4109: RAISE FND_API.G_EXC_ERROR;

4105: , p_error_table_name => L_table_name
4106: , p_message_name => L_message_name
4107: );
4108: --
4109: RAISE FND_API.G_EXC_ERROR;
4110: ELSIF
4111: x_errorcode < 0 THEN
4112: -- Write INTO interface error TABLE
4113: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(

Line 4119: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4115: , p_error_column_name => 'unexpected error'
4116: , p_error_table_name => 'unexpected error'
4117: , p_message_name => 'unexpected error'
4118: );
4119: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4120: END IF;
4121: --
4122: -- IS item under locator control
4123: IF (l_debug = 1) THEN

Line 4190: RAISE FND_API.G_EXC_ERROR;

4186: , p_error_table_name => L_table_name
4187: , p_message_name => L_message_name
4188: );
4189: --
4190: RAISE FND_API.G_EXC_ERROR;
4191: ELSIF
4192: x_errorcode < 0 THEN
4193: -- Write INTO interface error TABLE
4194: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(

Line 4200: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4196: , p_error_column_name => 'unexpected error'
4197: , p_error_table_name => 'unexpected error'
4198: , p_message_name => 'unexpected error'
4199: );
4200: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4201: END IF;
4202: --
4203:
4204: -- XXX big mess here (locator check should be based on a control level

Line 4257: RAISE FND_API.G_EXC_ERROR;

4253: , p_error_column_name => L_column_name
4254: , p_error_table_name => L_table_name
4255: , p_message_name => L_message_name
4256: );
4257: RAISE FND_API.G_EXC_ERROR;
4258: ELSIF
4259: x_errorcode < 0 THEN
4260: --
4261: -- Write INTO interface error TABLE

Line 4268: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4264: , p_error_column_name => 'unexpected error'
4265: , p_error_table_name => 'unexpected error'
4266: , p_message_name => 'unexpected error'
4267: );
4268: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4269: END IF;
4270: -- location contorl code is either no locator control, determined at
4271: -- subinv level or determined at item level
4272: ELSE

Line 4317: RAISE FND_API.G_EXC_ERROR;

4313: , p_error_column_name => L_column_name
4314: , p_error_table_name => L_table_name
4315: , p_message_name => L_message_name
4316: );
4317: RAISE FND_API.G_EXC_ERROR;
4318: ELSIF
4319: x_errorcode < 0 THEN
4320: --
4321: -- Write INTO interface error TABLE

Line 4328: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4324: , p_error_column_name => 'unexpected error'
4325: , p_error_table_name => 'unexpected error'
4326: , p_message_name => 'unexpected error'
4327: );
4328: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4329: END IF;
4330: END IF;
4331: --
4332: -- IS the item under lot control

Line 4399: RAISE FND_API.G_EXC_ERROR;

4395: , p_error_column_name => L_column_name
4396: , p_error_table_name => L_table_name
4397: , p_message_name => L_message_name
4398: );
4399: RAISE FND_API.G_EXC_ERROR;
4400: ELSIF
4401: x_errorcode < 0 THEN
4402: --
4403: IF (l_debug = 1) THEN

Line 4413: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4409: , p_error_column_name => 'unexpected error'
4410: , p_error_table_name => 'unexpected error'
4411: , p_message_name => 'unexpected error'
4412: );
4413: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4414: END IF;
4415: END IF;
4416: --
4417: -- IS the item under serial control

Line 4510: RAISE FND_API.G_EXC_ERROR;

4506: , p_error_column_name => L_column_name
4507: , p_error_table_name => L_table_name
4508: , p_message_name => L_message_name
4509: );
4510: RAISE FND_API.G_EXC_ERROR;
4511: ELSIF
4512: x_errorcode < 0 THEN
4513: --
4514: -- Write INTO interface error TABLE

Line 4521: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4517: , p_error_column_name => 'unexpected error'
4518: , p_error_table_name => 'unexpected error'
4519: , p_message_name => 'unexpected error'
4520: );
4521: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4522: END IF;
4523: IF (l_debug = 1) THEN
4524: MDEBUG( 'After call Validate_Serial Error Routine');
4525: END IF;

Line 4590: RAISE FND_API.G_EXC_ERROR;

4586: , p_error_column_name => '*'
4587: , p_error_table_name => 'MTL_CYCLE_COUNT_ENTRIES'
4588: , p_message_name => 'INV_CCEOI_NO_CCENTRY'
4589: );
4590: RAISE FND_API.G_EXC_ERROR;
4591: ELSIF
4592: L_counter > 1 OR (L_counter = 1 AND l_is_Unscheduled_Request) THEN
4593: -- XXX it is impossible to have multiple open
4594: -- requests existing for the same item/location

Line 4611: RAISE FND_API.G_EXC_ERROR;

4607: , p_error_column_name => '*'
4608: , p_error_table_name => 'MTL_CYCLE_COUNT_ENTRIES'
4609: , p_message_name => 'INV_CCEOI_MULT_REQUESTS'
4610: );
4611: RAISE FND_API.G_EXC_ERROR;
4612: END IF;
4613: --
4614: IF (l_debug = 1) THEN
4615: MDEBUG( 'Process: In Validate_ItemSKU call-5 ');

Line 4619: IF FND_API.to_Boolean(p_commit) THEN

4615: MDEBUG( 'Process: In Validate_ItemSKU call-5 ');
4616: END IF;
4617: -- END of API body
4618: -- Standard check of p_commit
4619: IF FND_API.to_Boolean(p_commit) THEN
4620: COMMIT;
4621: END IF;
4622: IF (l_debug = 1) THEN
4623: MDEBUG( 'Process: In Validate_ItemSKU call-6 ');

Line 4633: WHEN FND_API.G_EXC_ERROR THEN

4629: IF (l_debug = 1) THEN
4630: MDEBUG( 'Process: In Validate_ItemSKU call-7 ');
4631: END IF;
4632: EXCEPTION
4633: WHEN FND_API.G_EXC_ERROR THEN
4634: --
4635: x_return_status := FND_API.G_RET_STS_ERROR;
4636: --
4637: IF (l_debug = 1) THEN

Line 4635: x_return_status := FND_API.G_RET_STS_ERROR;

4631: END IF;
4632: EXCEPTION
4633: WHEN FND_API.G_EXC_ERROR THEN
4634: --
4635: x_return_status := FND_API.G_RET_STS_ERROR;
4636: --
4637: IF (l_debug = 1) THEN
4638: MDEBUG( 'ItemSKU-Error');
4639: END IF;

Line 4643: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

4639: END IF;
4640: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
4641: , p_data => x_msg_data);
4642: --
4643: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
4644: --
4645: x_errorcode := -1;
4646: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
4647: IF (l_debug = 1) THEN

Line 4646: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

4642: --
4643: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
4644: --
4645: x_errorcode := -1;
4646: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
4647: IF (l_debug = 1) THEN
4648: MDEBUG( 'ItemSKU-Unexp Error');
4649: END IF;
4650: --

Line 4657: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

4653: --
4654: WHEN OTHERS THEN
4655: --
4656: x_errorcode := -1;
4657: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
4658: IF (l_debug = 1) THEN
4659: MDEBUG( 'ItemSKU-Others Error');
4660: END IF;
4661: --

Line 4674: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,

4670: --
4671: -- Validate the UOM and quantity information
4672: PROCEDURE Validate_UOMQuantity(
4673: p_api_version IN NUMBER ,
4674: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
4675: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
4676: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
4677: x_return_status OUT NOCOPY VARCHAR2 ,
4678: x_msg_count OUT NOCOPY NUMBER ,

Line 4675: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,

4671: -- Validate the UOM and quantity information
4672: PROCEDURE Validate_UOMQuantity(
4673: p_api_version IN NUMBER ,
4674: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
4675: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
4676: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
4677: x_return_status OUT NOCOPY VARCHAR2 ,
4678: x_msg_count OUT NOCOPY NUMBER ,
4679: x_msg_data OUT NOCOPY VARCHAR2 ,

Line 4676: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,

4672: PROCEDURE Validate_UOMQuantity(
4673: p_api_version IN NUMBER ,
4674: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
4675: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
4676: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
4677: x_return_status OUT NOCOPY VARCHAR2 ,
4678: x_msg_count OUT NOCOPY NUMBER ,
4679: x_msg_data OUT NOCOPY VARCHAR2 ,
4680: x_errorcode OUT NOCOPY NUMBER ,

Line 4709: -- DEFAULT = FND_API.G_FALSE,

4705: -- p_api_version IN NUMBER (required)
4706: -- API Version of this procedure
4707: --
4708: -- p_init_msg_list IN VARCHAR2 (optional)
4709: -- DEFAULT = FND_API.G_FALSE,
4710: --
4711: -- p_commit IN VARCHAR2 (optional)
4712: -- DEFAULT = FND_API.G_FALSE
4713: --

Line 4712: -- DEFAULT = FND_API.G_FALSE

4708: -- p_init_msg_list IN VARCHAR2 (optional)
4709: -- DEFAULT = FND_API.G_FALSE,
4710: --
4711: -- p_commit IN VARCHAR2 (optional)
4712: -- DEFAULT = FND_API.G_FALSE
4713: --
4714: -- p_validation_level IN NUMBER (optional)
4715: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
4716: --

Line 4715: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,

4711: -- p_commit IN VARCHAR2 (optional)
4712: -- DEFAULT = FND_API.G_FALSE
4713: --
4714: -- p_validation_level IN NUMBER (optional)
4715: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
4716: --
4717: -- p_primary_uom_quantity IN NUMBER (required - default)
4718: -- default NULL
4719: -- Quantity within the primary unit OF measure OF the item

Line 4790: IF NOT FND_API.Compatible_API_Call(l_api_version

4786: -- Standard start of API savepoint
4787: SAVEPOINT Validate_UOMQuantity;
4788: --
4789: -- Standard Call to check for call compatibility
4790: IF NOT FND_API.Compatible_API_Call(l_api_version
4791: , p_api_version
4792: , l_api_name
4793: , G_PKG_NAME) THEN
4794: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 4794: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4790: IF NOT FND_API.Compatible_API_Call(l_api_version
4791: , p_api_version
4792: , l_api_name
4793: , G_PKG_NAME) THEN
4794: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4795: END IF;
4796: --
4797: -- Initialize message list if p_init_msg_list is set to true
4798: IF FND_API.to_Boolean(p_init_msg_list) THEN

Line 4798: IF FND_API.to_Boolean(p_init_msg_list) THEN

4794: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4795: END IF;
4796: --
4797: -- Initialize message list if p_init_msg_list is set to true
4798: IF FND_API.to_Boolean(p_init_msg_list) THEN
4799: FND_MSG_PUB.initialize;
4800: END IF;
4801: --
4802: -- Initialisize API return status to access

Line 4803: x_return_status := FND_API.G_RET_STS_SUCCESS;

4799: FND_MSG_PUB.initialize;
4800: END IF;
4801: --
4802: -- Initialisize API return status to access
4803: x_return_status := FND_API.G_RET_STS_SUCCESS;
4804: x_errorcode := 0;
4805: --
4806: -- API body
4807: --

Line 4857: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4853: MTL_CCEOI_VAR_PVT.G_CC_ENTRY_INTERFACE_ID
4854: , p_error_column_name => 'unexpected error'
4855: , p_error_table_name => 'unexpected error'
4856: , p_message_name => 'unexpected error');
4857: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4858:
4859: ELSIF x_errorcode = 22 THEN
4860: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(
4861: p_cc_entry_interface_id =>

Line 4866: RAISE FND_API.G_EXC_ERROR;

4862: MTL_CCEOI_VAR_PVT.G_CC_ENTRY_INTERFACE_ID
4863: , p_error_column_name => 'COUNT_QUANTITY'
4864: , p_error_table_name => 'MTL_CYCLE_COUNT_ENTRIES'
4865: , p_message_name => 'INV_CCEOI_NEG_QTY');
4866: RAISE FND_API.G_EXC_ERROR;
4867:
4868: ELSIF x_errorcode = 60 THEN
4869: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(
4870: p_cc_entry_interface_id =>

Line 4875: RAISE FND_API.G_EXC_ERROR;

4871: MTL_CCEOI_VAR_PVT.G_CC_ENTRY_INTERFACE_ID
4872: , p_error_column_name => 'COUNT_QUANTITY'
4873: , p_error_table_name => 'MTL_CYCLE_COUNT_ENTRIES'
4874: , p_message_name => 'INV_SERIAL_QTY_MUST_BE_1');
4875: RAISE FND_API.G_EXC_ERROR;
4876:
4877: ELSIF x_errorcode = 61 THEN
4878: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(
4879: p_cc_entry_interface_id =>

Line 4884: RAISE FND_API.G_EXC_ERROR;

4880: MTL_CCEOI_VAR_PVT.G_CC_ENTRY_INTERFACE_ID
4881: , p_error_column_name => 'COUNT_QUANTITY'
4882: , p_error_table_name => 'MTL_CYCLE_COUNT_ENTRIES'
4883: , p_message_name => 'INV_GREATER_EQUAL_ZERO');
4884: RAISE FND_API.G_EXC_ERROR;
4885:
4886: --
4887: -- primary uom quantity IS NOT populated, THEN validate COUNT uom
4888: ELSIF x_errorcode = 19 THEN

Line 4918: RAISE FND_API.G_EXC_ERROR;

4914: 'UOM_CODE/UNIT_OF_MEASURE'
4915: , p_error_table_name => 'MTL_ITEM_UOMS_VIEW'
4916: , p_message_name => 'INV_CCEOI_NO_UOM'
4917: );
4918: RAISE FND_API.G_EXC_ERROR;
4919:
4920: ELSIF x_errorcode = 20 THEN
4921: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(
4922: p_cc_entry_interface_id =>

Line 4929: RAISE FND_API.G_EXC_ERROR;

4925: 'UOM_CODE/UNIT_OF_MEASURE'
4926: , p_error_table_name => 'MTL_ITEM_UOMS_VIEW'
4927: , p_message_name => 'INV_CCEOI_INVALID_UOM'
4928: );
4929: RAISE FND_API.G_EXC_ERROR;
4930:
4931: ELSIF x_errorcode < 0 THEN
4932:
4933: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(

Line 4939: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4935: MTL_CCEOI_VAR_PVT.G_CC_ENTRY_INTERFACE_ID
4936: , p_error_column_name => 'unexpected error'
4937: , p_error_table_name => 'unexpected error'
4938: , p_message_name => 'unexpected error');
4939: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4940:
4941: END IF;
4942:
4943: --mdebug('Process: In Validate_UOMQuantity call Validate_CountQty ');

Line 4966: RAISE FND_API.G_EXC_ERROR;

4962: , p_error_column_name => 'COUNT_QUANTITY'
4963: , p_error_table_name => 'MTL_CYCLE_COUNT_ENTRIES'
4964: , p_message_name => 'INV_CCEOI_NEG_QTY');
4965:
4966: RAISE FND_API.G_EXC_ERROR;
4967: ELSIF x_errorcode = 60 THEN
4968:
4969: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(
4970: p_cc_entry_interface_id =>

Line 4976: RAISE FND_API.G_EXC_ERROR;

4972: , p_error_column_name => 'COUNT_QUANTITY'
4973: , p_error_table_name => 'MTL_CC_ENTRIES_INTERFACE'
4974: , p_message_name => 'INV_SERIAL_QTY_MUST_BE_1');
4975:
4976: RAISE FND_API.G_EXC_ERROR;
4977: ELSIF x_errorcode = 61 THEN
4978:
4979: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(
4980: p_cc_entry_interface_id =>

Line 4986: RAISE FND_API.G_EXC_ERROR;

4982: , p_error_column_name => 'COUNT_QUANTITY'
4983: , p_error_table_name => 'MTL_CC_ENTRIES_INTERFACE'
4984: , p_message_name => 'INV_GREATER_EQUAL_ZERO');
4985:
4986: RAISE FND_API.G_EXC_ERROR;
4987:
4988: ELSIF x_errorcode < 0 THEN
4989: -- Write INTO interface error TABLE
4990: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(

Line 4997: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

4993: , p_error_column_name => 'unexpected error'
4994: , p_error_table_name => 'unexpected error'
4995: , p_message_name => 'unexpected error');
4996:
4997: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
4998: END IF;
4999:
5000: END IF;
5001:

Line 5041: RAISE FND_API.G_EXC_ERROR;

5037: , p_error_table_name => 'MTL_ONHAND_QUANTITIES'
5038: , p_message_name => 'INV_CCEOI_ADJCALC_NO_SERIAL'
5039: );
5040: --
5041: RAISE FND_API.G_EXC_ERROR;
5042: ELSIF
5043: x_errorcode < 0 THEN
5044: -- Write INTO interface error TABLE
5045: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(

Line 5051: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

5047: , p_error_column_name => 'unexpected error'
5048: , p_error_table_name => 'unexpected error'
5049: , p_message_name => 'unexpected error'
5050: );
5051: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5052: END IF;
5053:
5054: ELSE -- XXX this is just a precaution (should never happen)
5055: IF (l_debug = 1) THEN

Line 5064: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

5060: , p_error_column_name => 'unexpected error'
5061: , p_error_table_name => 'unexpected error'
5062: , p_message_name => 'unexpected error'
5063: );
5064: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5065: END IF;
5066: --
5067: -- END of API body
5068: -- Standard check of p_commit

Line 5069: IF FND_API.to_Boolean(p_commit) THEN

5065: END IF;
5066: --
5067: -- END of API body
5068: -- Standard check of p_commit
5069: IF FND_API.to_Boolean(p_commit) THEN
5070: COMMIT;
5071: END IF;
5072: -- Standard call to get message count and if count is 1, get message info
5073: FND_MSG_PUB.Count_And_Get

Line 5077: WHEN FND_API.G_EXC_ERROR THEN

5073: FND_MSG_PUB.Count_And_Get
5074: (p_count => x_msg_count
5075: , p_data => x_msg_data);
5076: EXCEPTION
5077: WHEN FND_API.G_EXC_ERROR THEN
5078: --
5079: x_return_status := FND_API.G_RET_STS_ERROR;
5080: --
5081: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count

Line 5079: x_return_status := FND_API.G_RET_STS_ERROR;

5075: , p_data => x_msg_data);
5076: EXCEPTION
5077: WHEN FND_API.G_EXC_ERROR THEN
5078: --
5079: x_return_status := FND_API.G_RET_STS_ERROR;
5080: --
5081: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
5082: , p_data => x_msg_data);
5083: --

Line 5084: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

5080: --
5081: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
5082: , p_data => x_msg_data);
5083: --
5084: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
5085: --
5086: x_errorcode := -1;
5087: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5088: --

Line 5087: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

5083: --
5084: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
5085: --
5086: x_errorcode := -1;
5087: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5088: --
5089: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
5090: , p_data => x_msg_data);
5091: --

Line 5095: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

5091: --
5092: WHEN OTHERS THEN
5093: --
5094: x_errorcode := -1;
5095: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5096: --
5097: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
5098: FND_MSG_PUB.Add_Exc_Msg(G_PKG_NAME, l_api_name);
5099: END IF;

Line 5109: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,

5105: --
5106: -- Validate count date and counter
5107: PROCEDURE Validate_CDate_Counter(
5108: p_api_version IN NUMBER ,
5109: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5110: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5111: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
5112: x_return_status OUT NOCOPY VARCHAR2 ,
5113: x_msg_count OUT NOCOPY NUMBER ,

Line 5110: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,

5106: -- Validate count date and counter
5107: PROCEDURE Validate_CDate_Counter(
5108: p_api_version IN NUMBER ,
5109: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5110: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5111: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
5112: x_return_status OUT NOCOPY VARCHAR2 ,
5113: x_msg_count OUT NOCOPY NUMBER ,
5114: x_msg_data OUT NOCOPY VARCHAR2 ,

Line 5111: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,

5107: PROCEDURE Validate_CDate_Counter(
5108: p_api_version IN NUMBER ,
5109: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5110: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5111: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
5112: x_return_status OUT NOCOPY VARCHAR2 ,
5113: x_msg_count OUT NOCOPY NUMBER ,
5114: x_msg_data OUT NOCOPY VARCHAR2 ,
5115: x_errorcode OUT NOCOPY NUMBER ,

Line 5133: -- DEFAULT = FND_API.G_FALSE,

5129: -- p_api_version IN NUMBER (required)
5130: -- API Version of this procedure
5131: --
5132: -- p_init_msg_list IN VARCHAR2 (optional)
5133: -- DEFAULT = FND_API.G_FALSE,
5134: --
5135: -- p_commit IN VARCHAR2 (optional)
5136: -- DEFAULT = FND_API.G_FALSE
5137: --

Line 5136: -- DEFAULT = FND_API.G_FALSE

5132: -- p_init_msg_list IN VARCHAR2 (optional)
5133: -- DEFAULT = FND_API.G_FALSE,
5134: --
5135: -- p_commit IN VARCHAR2 (optional)
5136: -- DEFAULT = FND_API.G_FALSE
5137: --
5138: -- p_validation_level IN NUMBER (optional)
5139: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
5140: --

Line 5139: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,

5135: -- p_commit IN VARCHAR2 (optional)
5136: -- DEFAULT = FND_API.G_FALSE
5137: --
5138: -- p_validation_level IN NUMBER (optional)
5139: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL,
5140: --
5141: -- p_employee_id IN NUMBER (required)
5142: -- EmployeeID OF the counter
5143: --

Line 5180: IF NOT FND_API.Compatible_API_Call(l_api_version

5176: -- Standard start of API savepoint
5177: SAVEPOINT Validate_CDate_Counter;
5178: --
5179: -- Standard Call to check for call compatibility
5180: IF NOT FND_API.Compatible_API_Call(l_api_version
5181: , p_api_version
5182: , l_api_name
5183: , G_PKG_NAME) THEN
5184: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 5184: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

5180: IF NOT FND_API.Compatible_API_Call(l_api_version
5181: , p_api_version
5182: , l_api_name
5183: , G_PKG_NAME) THEN
5184: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5185: END IF;
5186: --
5187: -- Initialize message list if p_init_msg_list is set to true
5188: IF FND_API.to_Boolean(p_init_msg_list) THEN

Line 5188: IF FND_API.to_Boolean(p_init_msg_list) THEN

5184: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5185: END IF;
5186: --
5187: -- Initialize message list if p_init_msg_list is set to true
5188: IF FND_API.to_Boolean(p_init_msg_list) THEN
5189: FND_MSG_PUB.initialize;
5190: END IF;
5191: --
5192: -- Initialisize API return status to access

Line 5193: x_return_status := FND_API.G_RET_STS_SUCCESS;

5189: FND_MSG_PUB.initialize;
5190: END IF;
5191: --
5192: -- Initialisize API return status to access
5193: x_return_status := FND_API.G_RET_STS_SUCCESS;
5194: x_errorcode := 0;
5195: --
5196: -- API body
5197: --

Line 5223: RAISE FND_API.G_EXC_ERROR;

5219: , p_error_table_name => 'MTL_CYCLE_COUNT_HEADERS'
5220: , p_message_name => 'INV_CCEOI_COUNT_DATE_FUTURE'
5221: );
5222: --
5223: RAISE FND_API.G_EXC_ERROR;
5224: --
5225: ELSIF x_errorcode = 59 THEN -- New errorcode ( existing one )
5226: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(
5227: p_cc_entry_interface_id => MTL_CCEOI_VAR_PVT.G_CC_ENTRY_INTERFACE_ID

Line 5233: RAISE FND_API.G_EXC_ERROR;

5229: , p_error_table_name => 'MTL_CYCLE_COUNT_HEADERS'
5230: , p_message_name => 'INV_COUNT_DATE_FUTURE'
5231: );
5232: --
5233: RAISE FND_API.G_EXC_ERROR;
5234: ELSIF x_errorcode = 24 THEN
5235: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(
5236: p_cc_entry_interface_id => MTL_CCEOI_VAR_PVT.G_CC_ENTRY_INTERFACE_ID
5237: , p_error_column_name => 'COUNT_DATE'

Line 5242: RAISE FND_API.G_EXC_ERROR;

5238: , p_error_table_name => 'MTL_CYCLE_COUNT_HEADERS'
5239: , p_message_name => 'INV_CCEOI_NO_OPEN_ADJ_PRD'
5240: );
5241: --
5242: RAISE FND_API.G_EXC_ERROR;
5243:
5244: ELSIF
5245: x_errorcode < 0 THEN
5246: -- Write INTO interface error TABLE

Line 5253: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

5249: , p_error_column_name => 'unexpected error'
5250: , p_error_table_name => 'unexpected error'
5251: , p_message_name => 'unexpected error'
5252: );
5253: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5254: END IF;
5255: --
5256: IF (l_debug = 1) THEN
5257: mdebug('Process: In Validate_CDate_Counter call Validate_Employee');

Line 5299: RAISE FND_API.G_EXC_ERROR;

5295: , p_error_table_name => 'MTL_EMPLOYEES_CURRENT_VIEW'
5296: , p_message_name => L_message_name
5297: );
5298: --
5299: RAISE FND_API.G_EXC_ERROR;
5300: ELSIF
5301: x_errorcode < 0 THEN
5302: -- Write INTO interface error TABLE
5303: MTL_CCEOI_PROCESS_PVT.Insert_CCEOIError(

Line 5309: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

5305: , p_error_column_name => 'unexpected error'
5306: , p_error_table_name => 'unexpected error'
5307: , p_message_name => 'unexpected error'
5308: );
5309: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5310: END IF;
5311: --
5312: -- END of API body
5313: -- Standard check of p_commit

Line 5314: IF FND_API.to_Boolean(p_commit) THEN

5310: END IF;
5311: --
5312: -- END of API body
5313: -- Standard check of p_commit
5314: IF FND_API.to_Boolean(p_commit) THEN
5315: COMMIT;
5316: END IF;
5317: -- Standard call to get message count and if count is 1, get message info
5318: FND_MSG_PUB.Count_And_Get

Line 5322: WHEN FND_API.G_EXC_ERROR THEN

5318: FND_MSG_PUB.Count_And_Get
5319: (p_count => x_msg_count
5320: , p_data => x_msg_data);
5321: EXCEPTION
5322: WHEN FND_API.G_EXC_ERROR THEN
5323: --
5324: x_return_status := FND_API.G_RET_STS_ERROR;
5325: --
5326: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count

Line 5324: x_return_status := FND_API.G_RET_STS_ERROR;

5320: , p_data => x_msg_data);
5321: EXCEPTION
5322: WHEN FND_API.G_EXC_ERROR THEN
5323: --
5324: x_return_status := FND_API.G_RET_STS_ERROR;
5325: --
5326: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
5327: , p_data => x_msg_data);
5328: --

Line 5329: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

5325: --
5326: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
5327: , p_data => x_msg_data);
5328: --
5329: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
5330: --
5331: x_errorcode := -1;
5332: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5333: --

Line 5332: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

5328: --
5329: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
5330: --
5331: x_errorcode := -1;
5332: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5333: --
5334: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
5335: , p_data => x_msg_data);
5336: --

Line 5340: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

5336: --
5337: WHEN OTHERS THEN
5338: --
5339: x_errorcode := -1;
5340: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5341: --
5342: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
5343: FND_MSG_PUB.Add_Exc_Msg(G_PKG_NAME, l_api_name);
5344: END IF;

Line 5526: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,

5522: -- The logic which handles serial numbers is copied from INVATCEN.pld
5523: -- and will need further review/rewrite
5524: PROCEDURE Process_Data(
5525: p_api_version IN NUMBER ,
5526: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5527: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5528: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
5529: x_return_status OUT NOCOPY VARCHAR2 ,
5530: x_msg_count OUT NOCOPY NUMBER ,

Line 5527: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,

5523: -- and will need further review/rewrite
5524: PROCEDURE Process_Data(
5525: p_api_version IN NUMBER ,
5526: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5527: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5528: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
5529: x_return_status OUT NOCOPY VARCHAR2 ,
5530: x_msg_count OUT NOCOPY NUMBER ,
5531: x_msg_data OUT NOCOPY VARCHAR2 ,

Line 5528: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,

5524: PROCEDURE Process_Data(
5525: p_api_version IN NUMBER ,
5526: p_init_msg_list IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5527: p_commit IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5528: p_validation_level IN NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL,
5529: x_return_status OUT NOCOPY VARCHAR2 ,
5530: x_msg_count OUT NOCOPY NUMBER ,
5531: x_msg_data OUT NOCOPY VARCHAR2 ,
5532: x_errorcode OUT NOCOPY NUMBER ,

Line 5533: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE,

5529: x_return_status OUT NOCOPY VARCHAR2 ,
5530: x_msg_count OUT NOCOPY NUMBER ,
5531: x_msg_data OUT NOCOPY VARCHAR2 ,
5532: x_errorcode OUT NOCOPY NUMBER ,
5533: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE,
5534: p_interface_rec IN MTL_CCEOI_VAR_PVT.INV_CCEOI_TYPE )
5535: IS
5536: l_debug number := NVL(FND_PROFILE.VALUE('INV_DEBUG_TRACE'),0);
5537: BEGIN

Line 5552: -- DEFAULT = FND_API.G_FALSE,

5548: -- p_api_version IN NUMBER (required)
5549: -- API Version of this procedure
5550: --
5551: -- p_init_msg_list IN VARCHAR2 (optional)
5552: -- DEFAULT = FND_API.G_FALSE,
5553: --
5554: -- p_commit IN VARCHAR2 (optional)
5555: --
5556: -- DEFAULT = FND_API.G_FALSE

Line 5556: -- DEFAULT = FND_API.G_FALSE

5552: -- DEFAULT = FND_API.G_FALSE,
5553: --
5554: -- p_commit IN VARCHAR2 (optional)
5555: --
5556: -- DEFAULT = FND_API.G_FALSE
5557: -- p_validation_level IN NUMBER (optional)
5558: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL
5559: -- currently unused
5560: --

Line 5558: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL

5554: -- p_commit IN VARCHAR2 (optional)
5555: --
5556: -- DEFAULT = FND_API.G_FALSE
5557: -- p_validation_level IN NUMBER (optional)
5558: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL
5559: -- currently unused
5560: --
5561: -- p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE
5562: -- G_TRUE - skip any updates/inserts to any non-cc-interface tables

Line 5561: -- p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE

5557: -- p_validation_level IN NUMBER (optional)
5558: -- DEFAULT = FND_API.G_VALID_LEVEL_FULL
5559: -- currently unused
5560: --
5561: -- p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE
5562: -- G_TRUE - skip any updates/inserts to any non-cc-interface tables
5563: -- G_FALSE - update any tables necessary
5564: --
5565: -- p_interface_rec MTL_CC_ENTRIES_INTERFACE%rowtype (required)

Line 5622: IF NOT FND_API.Compatible_API_Call(l_api_version

5618: -- Standard start of API savepoint
5619: SAVEPOINT Process_Data;
5620: --
5621: -- Standard Call to check for call compatibility
5622: IF NOT FND_API.Compatible_API_Call(l_api_version
5623: , p_api_version
5624: , l_api_name
5625: , G_PKG_NAME) THEN
5626: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

Line 5626: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

5622: IF NOT FND_API.Compatible_API_Call(l_api_version
5623: , p_api_version
5624: , l_api_name
5625: , G_PKG_NAME) THEN
5626: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5627: END IF;
5628: --
5629: -- Initialize message list if p_init_msg_list is set to true
5630: IF FND_API.to_Boolean(p_init_msg_list) THEN

Line 5630: IF FND_API.to_Boolean(p_init_msg_list) THEN

5626: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5627: END IF;
5628: --
5629: -- Initialize message list if p_init_msg_list is set to true
5630: IF FND_API.to_Boolean(p_init_msg_list) THEN
5631: FND_MSG_PUB.initialize;
5632: END IF;
5633: --
5634: -- Initialisize API return status to access

Line 5635: x_return_status := FND_API.G_RET_STS_SUCCESS;

5631: FND_MSG_PUB.initialize;
5632: END IF;
5633: --
5634: -- Initialisize API return status to access
5635: x_return_status := FND_API.G_RET_STS_SUCCESS;
5636: x_errorcode := 0;
5637: --
5638: -- API body
5639: IF (l_debug = 1) THEN

Line 5730: IF NOT FND_API.to_Boolean(p_simulate) THEN

5726: MDEBUG( 'Process Data: Not equal sys and count qties');
5727: MDEBUG( 'Process Data: level '||to_char(p_validation_level));
5728: END IF;
5729: --
5730: IF NOT FND_API.to_Boolean(p_simulate) THEN
5731: --
5732: IF (l_debug = 1) THEN
5733: MDEBUG( 'Process Data: mark RECORD as locked ');
5734: MDEBUG( 'Process Data: Sl# '||p_interface_rec.serial_number);

Line 5763: --RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

5759: p_interface_rec.serial_number);
5760: FND_MSG_PUB.Add;
5761: --x_errorcode := -1;
5762: x_errorcode := 70;
5763: --RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5764: RAISE FND_API.G_EXC_ERROR;
5765: --
5766: END IF;
5767: END IF;

Line 5764: RAISE FND_API.G_EXC_ERROR;

5760: FND_MSG_PUB.Add;
5761: --x_errorcode := -1;
5762: x_errorcode := 70;
5763: --RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
5764: RAISE FND_API.G_EXC_ERROR;
5765: --
5766: END IF;
5767: END IF;
5768: --

Line 5803: if p_simulate = FND_API.G_FALSE THEN

5799: mdebug('Process: In Process_Data with serial one per request Completed');
5800: END IF;
5801:
5802: -- if p_validation_level = 1 THEN
5803: if p_simulate = FND_API.G_FALSE THEN
5804: serial_check.inv_unmark_serial(
5805: from_serial_number => p_interface_rec.serial_number
5806: , to_serial_number => p_interface_rec.serial_number
5807: , serial_code => MTL_CCEOI_VAR_PVT.G_SKU_REC.SERIAL_NUMBER_CONTROL_CODE

Line 5822: IF FND_API.to_Boolean(p_commit) THEN

5818: END IF;
5819: --
5820: -- END of API body
5821: -- Standard check of p_commit
5822: IF FND_API.to_Boolean(p_commit) THEN
5823: COMMIT;
5824: END IF;
5825: -- Standard call to get message count and if count is 1, get message info
5826: FND_MSG_PUB.Count_And_Get

Line 5830: WHEN FND_API.G_EXC_ERROR THEN

5826: FND_MSG_PUB.Count_And_Get
5827: (p_count => x_msg_count
5828: , p_data => x_msg_data);
5829: EXCEPTION
5830: WHEN FND_API.G_EXC_ERROR THEN
5831: --
5832: ROLLBACK TO Process_Data;
5833: --
5834: x_return_status := FND_API.G_RET_STS_ERROR;

Line 5834: x_return_status := FND_API.G_RET_STS_ERROR;

5830: WHEN FND_API.G_EXC_ERROR THEN
5831: --
5832: ROLLBACK TO Process_Data;
5833: --
5834: x_return_status := FND_API.G_RET_STS_ERROR;
5835: --
5836: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
5837: , p_data => x_msg_data);
5838: --

Line 5839: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

5835: --
5836: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
5837: , p_data => x_msg_data);
5838: --
5839: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
5840: --
5841: ROLLBACK TO Process_Data;
5842: --
5843: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

Line 5843: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

5839: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
5840: --
5841: ROLLBACK TO Process_Data;
5842: --
5843: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5844: --
5845: x_errorcode := -1;
5846: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count
5847: , p_data => x_msg_data);

Line 5854: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

5850: --
5851: ROLLBACK TO Process_Data;
5852: --
5853: x_errorcode := -1;
5854: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
5855: --
5856: IF FND_MSG_PUB.Check_Msg_Level(FND_MSG_PUB.G_MSG_LVL_UNEXP_ERROR) THEN
5857: FND_MSG_PUB.Add_Exc_Msg(G_PKG_NAME, l_api_name);
5858: END IF;

Line 5902: X_return_status := FND_API.G_RET_STS_SUCCESS;

5898: DECLARE
5899: dummy integer;
5900:
5901: BEGIN
5902: X_return_status := FND_API.G_RET_STS_SUCCESS;
5903: -- update RECORD to be successful
5904: --
5905: BEGIN
5906: --

Line 6088: X_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

6084: --
6085: END IF;
6086: EXCEPTION
6087: WHEN OTHERS THEN
6088: X_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
6089: END;
6090: END;
6091: END;
6092:

Line 6109: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE )

6105: -- post:
6106: --
6107: FUNCTION check_serial_location(
6108: P_issue_receipt IN VARCHAR2,
6109: p_simulate IN VARCHAR2 DEFAULT FND_API.G_FALSE )
6110: return BOOLEAN
6111: IS
6112: l_return_status VARCHAR2(1);
6113: l_errorcode NUMBER;

Line 6151: if (l_return_status <> FND_API.G_RET_STS_SUCCESS) then

6147: p_receipt_issue_flag => p_issue_receipt,
6148: p_simulate => p_simulate);
6149:
6150:
6151: if (l_return_status <> FND_API.G_RET_STS_SUCCESS) then
6152: return (FALSE);
6153: end if;
6154:
6155:

Line 6199: P_INIT_MSG_LIST VARCHAR2(30) DEFAULT FND_API.G_FALSE;

6195: v_msn_revision varchar2(3);
6196: v_current_status number;
6197: --
6198: P_api_version NUMBER := 0.9;
6199: P_INIT_MSG_LIST VARCHAR2(30) DEFAULT FND_API.G_FALSE;
6200: P_COMMIT VARCHAR2(30) DEFAULT FND_API.G_FALSE;
6201: P_VALIDATION_LEVEL NUMBER := 1;
6202: -- P_VALIDATION_LEVEL NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL;
6203: X_RETURN_STATUS VARCHAR2(90);

Line 6200: P_COMMIT VARCHAR2(30) DEFAULT FND_API.G_FALSE;

6196: v_current_status number;
6197: --
6198: P_api_version NUMBER := 0.9;
6199: P_INIT_MSG_LIST VARCHAR2(30) DEFAULT FND_API.G_FALSE;
6200: P_COMMIT VARCHAR2(30) DEFAULT FND_API.G_FALSE;
6201: P_VALIDATION_LEVEL NUMBER := 1;
6202: -- P_VALIDATION_LEVEL NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL;
6203: X_RETURN_STATUS VARCHAR2(90);
6204: X_MSG_COUNT NUMBER;

Line 6202: -- P_VALIDATION_LEVEL NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL;

6198: P_api_version NUMBER := 0.9;
6199: P_INIT_MSG_LIST VARCHAR2(30) DEFAULT FND_API.G_FALSE;
6200: P_COMMIT VARCHAR2(30) DEFAULT FND_API.G_FALSE;
6201: P_VALIDATION_LEVEL NUMBER := 1;
6202: -- P_VALIDATION_LEVEL NUMBER DEFAULT FND_API.G_VALID_LEVEL_FULL;
6203: X_RETURN_STATUS VARCHAR2(90);
6204: X_MSG_COUNT NUMBER;
6205: X_MSG_DATA VARCHAR2(90);
6206: X_ERRORCODE NUMBER;

Line 6377: , p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false

6373:
6374: -- BEGIN INVCONV
6375: PROCEDURE validate_secondaryuomqty (
6376: p_api_version IN NUMBER
6377: , p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false
6378: , p_commit IN VARCHAR2 DEFAULT fnd_api.g_false
6379: , p_validation_level IN NUMBER DEFAULT fnd_api.g_valid_level_full
6380: , x_return_status OUT NOCOPY VARCHAR2
6381: , x_msg_count OUT NOCOPY NUMBER

Line 6378: , p_commit IN VARCHAR2 DEFAULT fnd_api.g_false

6374: -- BEGIN INVCONV
6375: PROCEDURE validate_secondaryuomqty (
6376: p_api_version IN NUMBER
6377: , p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false
6378: , p_commit IN VARCHAR2 DEFAULT fnd_api.g_false
6379: , p_validation_level IN NUMBER DEFAULT fnd_api.g_valid_level_full
6380: , x_return_status OUT NOCOPY VARCHAR2
6381: , x_msg_count OUT NOCOPY NUMBER
6382: , x_msg_data OUT NOCOPY VARCHAR2

Line 6379: , p_validation_level IN NUMBER DEFAULT fnd_api.g_valid_level_full

6375: PROCEDURE validate_secondaryuomqty (
6376: p_api_version IN NUMBER
6377: , p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false
6378: , p_commit IN VARCHAR2 DEFAULT fnd_api.g_false
6379: , p_validation_level IN NUMBER DEFAULT fnd_api.g_valid_level_full
6380: , x_return_status OUT NOCOPY VARCHAR2
6381: , x_msg_count OUT NOCOPY NUMBER
6382: , x_msg_data OUT NOCOPY VARCHAR2
6383: , x_errorcode OUT NOCOPY NUMBER

Line 6409: IF NOT fnd_api.compatible_api_call (l_api_version

6405: -- Standard start of API savepoint
6406: SAVEPOINT validate_uomquantity;
6407:
6408: -- Standard Call to check for call compatibility
6409: IF NOT fnd_api.compatible_api_call (l_api_version
6410: , p_api_version
6411: , l_api_name
6412: , g_pkg_name) THEN
6413: RAISE fnd_api.g_exc_unexpected_error;

Line 6413: RAISE fnd_api.g_exc_unexpected_error;

6409: IF NOT fnd_api.compatible_api_call (l_api_version
6410: , p_api_version
6411: , l_api_name
6412: , g_pkg_name) THEN
6413: RAISE fnd_api.g_exc_unexpected_error;
6414: END IF;
6415:
6416: -- Initialize message list if p_init_msg_list is set to true
6417: IF fnd_api.to_boolean (p_init_msg_list) THEN

Line 6417: IF fnd_api.to_boolean (p_init_msg_list) THEN

6413: RAISE fnd_api.g_exc_unexpected_error;
6414: END IF;
6415:
6416: -- Initialize message list if p_init_msg_list is set to true
6417: IF fnd_api.to_boolean (p_init_msg_list) THEN
6418: fnd_msg_pub.initialize;
6419: END IF;
6420:
6421: -- Initialisize API return status to success

Line 6422: x_return_status := fnd_api.g_ret_sts_success;

6418: fnd_msg_pub.initialize;
6419: END IF;
6420:
6421: -- Initialisize API return status to success
6422: x_return_status := fnd_api.g_ret_sts_success;
6423: x_errorcode := 0;
6424:
6425: --
6426: IF (l_debug = 1) THEN

Line 6472: RAISE fnd_api.g_exc_error;

6468: (p_cc_entry_interface_id => mtl_cceoi_var_pvt.g_cc_entry_interface_id
6469: , p_error_column_name => 'SECONDARY_UOM_CODE'
6470: , p_error_table_name => 'MTL_SYSTEM_ITEMS'
6471: , p_message_name => 'INV_INCORRECT_SECONDARY_UOM');
6472: RAISE fnd_api.g_exc_error;
6473: END IF;
6474:
6475: IF (l_debug = 1) THEN
6476: mdebug ( 'Process: In Validate_SecondaryUOMQty call Validate_SecondaryCountQty: '

Line 6511: RAISE fnd_api.g_exc_error;

6507: (p_cc_entry_interface_id => mtl_cceoi_var_pvt.g_cc_entry_interface_id
6508: , p_error_column_name => 'SECONDARY_COUNT_QUANTITY'
6509: , p_error_table_name => 'MTL_CC_ENTRIES_INTERFACE'
6510: , p_message_name => 'INV_NO_CONVERSION_ERR');
6511: RAISE fnd_api.g_exc_error;
6512: ELSIF x_errorcode = 51 THEN
6513: -- Write INTO interface error TABLE
6514: mtl_cceoi_process_pvt.insert_cceoierror
6515: (p_cc_entry_interface_id => mtl_cceoi_var_pvt.g_cc_entry_interface_id

Line 6519: RAISE fnd_api.g_exc_error;

6515: (p_cc_entry_interface_id => mtl_cceoi_var_pvt.g_cc_entry_interface_id
6516: , p_error_column_name => 'SECONDARY_COUNT_QUANTITY'
6517: , p_error_table_name => 'MTL_CC_ENTRIES_INTERFACE'
6518: , p_message_name => 'INV_DEVIATION_CHECK_ERR');
6519: RAISE fnd_api.g_exc_error;
6520: ELSIF x_errorcode = 52 THEN
6521: -- Write INTO interface error TABLE
6522: mtl_cceoi_process_pvt.insert_cceoierror
6523: (p_cc_entry_interface_id => mtl_cceoi_var_pvt.g_cc_entry_interface_id

Line 6527: RAISE fnd_api.g_exc_error;

6523: (p_cc_entry_interface_id => mtl_cceoi_var_pvt.g_cc_entry_interface_id
6524: , p_error_column_name => 'SECONDARY_COUNT_QUANTITY'
6525: , p_error_table_name => 'MTL_CC_ENTRIES_INTERFACE'
6526: , p_message_name => 'INV_CCEOI_NEG_QTY');
6527: RAISE fnd_api.g_exc_error;
6528: END IF;
6529:
6530: -- Calculate secondary adjustment quantity
6531: MTL_CCEOI_VAR_PVT.g_sec_adjustment_quantity :=

Line 6544: RAISE fnd_api.g_exc_unexpected_error;

6540: (p_cc_entry_interface_id => mtl_cceoi_var_pvt.g_cc_entry_interface_id
6541: , p_error_column_name => 'unexpected error'
6542: , p_error_table_name => 'unexpected error'
6543: , p_message_name => 'unexpected error');
6544: RAISE fnd_api.g_exc_unexpected_error;
6545: END IF; -- count type code
6546:
6547: -- Standard check of p_commit
6548: IF fnd_api.to_boolean (p_commit) THEN

Line 6548: IF fnd_api.to_boolean (p_commit) THEN

6544: RAISE fnd_api.g_exc_unexpected_error;
6545: END IF; -- count type code
6546:
6547: -- Standard check of p_commit
6548: IF fnd_api.to_boolean (p_commit) THEN
6549: COMMIT;
6550: END IF;
6551:
6552: -- Standard call to get message count and if count is 1, get message info

Line 6555: WHEN fnd_api.g_exc_error THEN

6551:
6552: -- Standard call to get message count and if count is 1, get message info
6553: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
6554: EXCEPTION
6555: WHEN fnd_api.g_exc_error THEN
6556: ROLLBACK TO validate_secondarycountuom;
6557: x_return_status := fnd_api.g_ret_sts_error;
6558: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
6559: WHEN fnd_api.g_exc_unexpected_error THEN

Line 6557: x_return_status := fnd_api.g_ret_sts_error;

6553: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
6554: EXCEPTION
6555: WHEN fnd_api.g_exc_error THEN
6556: ROLLBACK TO validate_secondarycountuom;
6557: x_return_status := fnd_api.g_ret_sts_error;
6558: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
6559: WHEN fnd_api.g_exc_unexpected_error THEN
6560: ROLLBACK TO validate_secondarycountuom;
6561: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 6559: WHEN fnd_api.g_exc_unexpected_error THEN

6555: WHEN fnd_api.g_exc_error THEN
6556: ROLLBACK TO validate_secondarycountuom;
6557: x_return_status := fnd_api.g_ret_sts_error;
6558: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
6559: WHEN fnd_api.g_exc_unexpected_error THEN
6560: ROLLBACK TO validate_secondarycountuom;
6561: x_return_status := fnd_api.g_ret_sts_unexp_error;
6562: x_errorcode := -1;
6563: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);

Line 6561: x_return_status := fnd_api.g_ret_sts_unexp_error;

6557: x_return_status := fnd_api.g_ret_sts_error;
6558: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
6559: WHEN fnd_api.g_exc_unexpected_error THEN
6560: ROLLBACK TO validate_secondarycountuom;
6561: x_return_status := fnd_api.g_ret_sts_unexp_error;
6562: x_errorcode := -1;
6563: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
6564: WHEN OTHERS THEN
6565: ROLLBACK TO validate_secondarycountuom;

Line 6567: x_return_status := fnd_api.g_ret_sts_unexp_error;

6563: fnd_msg_pub.count_and_get (p_count => x_msg_count, p_data => x_msg_data);
6564: WHEN OTHERS THEN
6565: ROLLBACK TO validate_secondarycountuom;
6566: x_errorcode := -1;
6567: x_return_status := fnd_api.g_ret_sts_unexp_error;
6568:
6569: IF fnd_msg_pub.check_msg_level (fnd_msg_pub.g_msg_lvl_unexp_error) THEN
6570: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
6571: END IF;