DBA Data[Home] [Help]

PACKAGE: APPS.CN_PRD_QUOTA_PUB

Source


1 PACKAGE CN_PRD_QUOTA_PUB AS
2 /*$Header: cnvpedbs.pls 120.1 2005/09/19 22:51:28 rarajara noship $*/
3 /*#
4  * The procedure in this package can be used to distribute the target of the specified plan element
5  * across the various periods. When the plan element is created, the target is not distributed by default.
6  * While the UI can be used to distribute the target by navigating to the individual plan elements,
7  * this package provides a convenient method to do the same by using SQL*PLUS.
8  * @rep:scope public
9  * @rep:product CN
10  * @rep:displayname Period Quotas distribution
11  * @rep:lifecycle active
12  * @rep:compatibility S
13  * @rep:category BUSINESS_ENTITY CN_COMP_PLANS
14  */
15 
16 -- period quota
17 TYPE prd_quota_rec_type IS RECORD
18   (
19      PERIOD_NAME      CN_PERIOD_STATUSES.PERIOD_NAME%TYPE := FND_API.G_MISS_CHAR,
20      PERIOD_TARGET    NUMBER := FND_API.G_MISS_NUM,
21      PERIOD_PAYMENT    NUMBER := FND_API.G_MISS_NUM,
22      PERFORMANCE_GOAL  NUMBER := FND_API.G_MISS_NUM
23   );
24 
25 
26 TYPE prd_quota_tbl_type IS
27    TABLE OF prd_quota_rec_type INDEX BY BINARY_INTEGER ;
28 
29 
30 
31 -- Global variable that represent missing values.
32 
33 G_MISS_PRD_QUOTA_REC  prd_quota_rec_type;
34 G_MISS_PRD_QUOTA_REC_TB  prd_quota_tbl_type;
35 
36 
37 /*#
38  * This procedure distributes the target for a plan element across the periods for which the plan element has been defined.
39  * @param p_api_version API version
40  * @param p_init_msg_list Initialize message list (default F)
41  * @param p_commit Commit flag (default F).
42  * @param p_validation_level Validation level (default 100).
43  * @param x_return_status Return Status
44  * @param x_msg_count Number of messages returned
45  * @param x_msg_data Contents of message if x_msg_count = 1
46  * @param p_pe_name The plan element for which the target has to be distributed.
47  * @param p_target_amount The target amount that has to be distributed across the periods.
48  * @param p_fixed_amount The fixed amount that has to be distributed for the periods.
49  * @param p_performance_goal The performance goal that has to be distributed for the periods.
50  * @param p_even_distribute The configuration parameter used to choose between even distribution and user configurable distribution. Y = even, N = user configurable.
51  * @param p_prd_quota_tbl The user configured distribution if p_even_distribute is set to N.
52  * @rep:lifecycle active
53  * @rep:displayname Delete Role Plan Assignment
54  */
55 
56 
57 PROCEDURE Distribute_Prd_Quota
58 (       p_api_version              IN   NUMBER   := CN_API.G_MISS_NUM,
59         p_init_msg_list            IN   VARCHAR2 := CN_API.G_FALSE,
60         p_commit                   IN   VARCHAR2 := CN_API.G_FALSE,
61         p_validation_level         IN   NUMBER   := CN_API.G_VALID_LEVEL_FULL,
62         p_pe_name                  IN   CN_QUOTAS.NAME%TYPE,
63         p_target_amount            IN   CN_QUOTAS.target%TYPE,
64         p_fixed_amount             IN   CN_QUOTAS.payment_amount%TYPE,
65         p_performance_goal         IN   CN_QUOTAS.performance_goal%TYPE,
66         p_even_distribute          IN   VARCHAR2,
67         p_prd_quota_tbl            IN   prd_quota_tbl_type,
68 				p_org_id									 IN  NUMBER,
69         x_return_status            OUT NOCOPY VARCHAR2,
70         x_msg_count                OUT NOCOPY NUMBER,
71         x_msg_data                 OUT NOCOPY VARCHAR2
72 
73   );
74 
75 
76 
77 
78 
79 
80 
81 END CN_PRD_QUOTA_PUB;