1 Package ota_tsr_ins AUTHID CURRENT_USER as
2 /* $Header: ottsr01t.pkh 120.1 2006/02/13 02:49:09 jbharath noship $ */
3 --
4 ---- ----------------------------------------------------------------------------
5 -- |------------------------< set_base_key_value >----------------------------|
6 -- ----------------------------------------------------------------------------
7 -- {Start of Comments}
8 -- Description:
9 -- This procedure is called to register the next ID value from the database
10 -- sequence.
11 --
12 -- Prerequisites:
13 --
14 -- In Parameters:
15 -- Primary Key
16 --
17 -- Post Success:
18 --
19 -- Post Failure:
20 --
21 -- Developer Implementation Notes:
22 -- None.
23 --
24 -- Access Status:
25 -- Internal Development Use Only.
26 --
27 -- {End of Comments}
28 -- ----------------------------------------------------------------------------
29 procedure set_base_key_value
30 (p_supplied_resource_id in number);
31 --
32 --
33
34 -- ----------------------------------------------------------------------------
35 -- |---------------------------------< ins >----------------------------------|
36 -- ----------------------------------------------------------------------------
37 -- {Start Of Comments}
38 --
39 -- Description:
40 -- This procedure is the record interface for the insert business process
41 -- for the specified entity. The role of this process is to insert a fully
42 -- validated row, into the HR schema passing back to the calling process,
43 -- any system generated values (e.g. primary and object version number
44 -- attributes). This process is the main backbone of the ins business
45 -- process. The processing of this procedure is as follows:
46 -- 1) If the p_validate argument has been set to true then a savepoint is
47 -- issued.
48 -- 2) The controlling validation process insert_validate is then executed
49 -- which will execute all private and public validation business rule
50 -- processes.
51 -- 3) The pre_insert business process is then executed which enables any
52 -- logic to be processed before the insert dml process is executed.
53 -- 4) The insert_dml process will physical perform the insert dml into the
54 -- specified entity.
55 -- 5) The post_insert business process is then executed which enables any
56 -- logic to be processed after the insert dml process.
57 -- 6) If the p_validate argument has been set to true an exception is raised
58 -- which is handled and processed by performing a rollback to the
59 -- savepoint which was issued at the beginning of the Ins process.
60 --
61 -- Pre Conditions:
62 -- The main arguments to the business process have to be in the record
63 -- format.
64 --
65 -- In Arguments:
66 -- p_validate
67 -- Determines if the business process is to be validated. Setting this
68 -- boolean value to true will invoke the process to be validated. The
69 -- default is false. The validation is controlled by a savepoint and
70 -- rollback mechanism. The savepoint is issued at the beginning of the
71 -- business process and is rollbacked at the end of the business process
72 -- when all the processing has been completed. The rollback is controlled
73 -- by raising and handling the exception hr_api.validate_enabled. We use
74 -- the exception because, by raising the exception with the business
75 -- process, we can exit successfully without having any of the 'OUT'
76 -- arguments being set.
77 --
78 -- Post Success:
79 -- A fully validated row will be inserted into the specified entity
80 -- without being committed. If the p_validate argument has been set to true
81 -- then all the work will be rolled back.
82 --
83 -- Post Failure:
84 -- If an error has occurred, an error message will be supplied with the work
85 -- rolled back.
86 --
87 -- Developer Implementation Notes:
88 -- None.
89 --
90 -- Access Status:
91 -- Public.
92 --
93 -- {End Of Comments}
94 -- ----------------------------------------------------------------------------
95 Procedure ins
96 (
97 p_rec in out nocopy ota_tsr_shd.g_rec_type,
98 p_validate in boolean default false
99 );
100 --
101 -- ----------------------------------------------------------------------------
102 -- |---------------------------------< ins >----------------------------------|
103 -- ----------------------------------------------------------------------------
104 -- {Start Of Comments}
105 --
106 -- Description:
107 -- This procedure is the attribute interface for the insert business
108 -- process for the specified entity and is the outermost layer. The role
109 -- of this process is to insert a fully validated row into the HR schema
110 -- passing back to the calling process, any system generated values
111 -- (e.g. object version number attributes).The processing of this
112 -- procedure is as follows:
113 -- 1) The attributes are converted into a local record structure by
114 -- calling the convert_args function.
115 -- 2) After the conversion has taken place, the corresponding record ins
116 -- interface business process is executed.
117 -- 3) OUT arguments are then set to their corresponding record arguments.
118 --
119 -- Pre Conditions:
120 --
121 -- In Arguments:
122 -- p_validate
123 -- Determines if the business process is to be validated. Setting this
124 -- Boolean value to true will invoke the process to be validated.
125 -- The default is false.
126 --
127 -- Post Success:
128 -- A fully validated row will be inserted for the specified entity
129 -- without being committed (or rollbacked depending on the p_validate
130 -- status).
131 --
132 -- Post Failure:
133 -- If an error has occurred, an error message will be supplied with the work
134 -- rolled back.
135 --
136 -- Developer Implementation Notes:
137 -- None.
138 --
139 -- Access Status:
140 -- Public.
141 --
142 -- {End Of Comments}
143 -- ----------------------------------------------------------------------------
144 Procedure ins
145 (
146 p_supplied_resource_id out nocopy number,
147 p_vendor_id in number,
148 p_business_group_id in number,
149 p_resource_definition_id in number,
150 p_consumable_flag in varchar2,
151 p_object_version_number out nocopy number,
152 p_resource_type in varchar2,
153 p_start_date in date,
154 p_comments in varchar2 default null,
155 p_cost in number default null,
156 p_cost_unit in varchar2 default null,
157 p_currency_code in varchar2 default null,
158 p_end_date in date default null,
159 p_internal_address_line in varchar2 default null,
160 p_lead_time in number default null,
161 p_name in varchar2 default null,
162 p_supplier_reference in varchar2 default null,
163 p_tsr_information_category in varchar2 default null,
164 p_tsr_information1 in varchar2 default null,
165 p_tsr_information2 in varchar2 default null,
166 p_tsr_information3 in varchar2 default null,
167 p_tsr_information4 in varchar2 default null,
168 p_tsr_information5 in varchar2 default null,
169 p_tsr_information6 in varchar2 default null,
170 p_tsr_information7 in varchar2 default null,
171 p_tsr_information8 in varchar2 default null,
172 p_tsr_information9 in varchar2 default null,
173 p_tsr_information10 in varchar2 default null,
174 p_tsr_information11 in varchar2 default null,
175 p_tsr_information12 in varchar2 default null,
176 p_tsr_information13 in varchar2 default null,
177 p_tsr_information14 in varchar2 default null,
178 p_tsr_information15 in varchar2 default null,
179 p_tsr_information16 in varchar2 default null,
180 p_tsr_information17 in varchar2 default null,
181 p_tsr_information18 in varchar2 default null,
182 p_tsr_information19 in varchar2 default null,
183 p_tsr_information20 in varchar2 default null,
184 p_training_center_id in number default null,
185 p_location_id in number default null,
186 p_trainer_id in number default null,
187 p_special_instruction in varchar2 default null,
188 p_validate in boolean default false
189 );
190 --
191 end ota_tsr_ins;