DBA Data[Home] [Help]

PACKAGE: APPS.PQH_PTE_SHD

Source


1 Package pqh_pte_shd AUTHID CURRENT_USER as
2 /* $Header: pqpterhi.pkh 120.0 2005/05/29 02:21:00 appldev noship $ */
3 --
4 -- ----------------------------------------------------------------------------
5 -- |                    Global Record Type Specification                      |
6 -- ----------------------------------------------------------------------------
7 --
8 Type g_rec_type Is Record
9   (
10   ptx_extra_info_id                 number(15),
11   information_type                  varchar2(40),
12   position_transaction_id           number(15),
13   position_extra_info_id            number(15),
14   information_category              varchar2(30),
15   information1                      varchar2(150),
16   information2                      varchar2(150),
17   information3                      varchar2(150),
18   information4                      varchar2(150),
19   information5                      varchar2(150),
20   information6                      varchar2(150),
21   information7                      varchar2(150),
22   information8                      varchar2(150),
23   information9                      varchar2(150),
24   information10                     varchar2(150),
25   information11                     varchar2(150),
26   information12                     varchar2(150),
27   information13                     varchar2(150),
28   information14                     varchar2(150),
29   information15                     varchar2(150),
30   information16                     varchar2(150),
31   information17                     varchar2(150),
32   information18                     varchar2(150),
33   information19                     varchar2(150),
34   information20                     varchar2(150),
35   information21                     varchar2(150),
36   information22                     varchar2(150),
37   information23                     varchar2(150),
38   information24                     varchar2(150),
39   information25                     varchar2(150),
40   information26                     varchar2(150),
41   information27                     varchar2(150),
42   information28                     varchar2(150),
43   information29                     varchar2(150),
44   information30                     varchar2(150),
45   attribute_category                varchar2(30),
46   attribute1                        varchar2(150),
47   attribute2                        varchar2(150),
48   attribute3                        varchar2(150),
49   attribute4                        varchar2(150),
50   attribute5                        varchar2(150),
51   attribute6                        varchar2(150),
52   attribute7                        varchar2(150),
53   attribute8                        varchar2(150),
54   attribute9                        varchar2(150),
55   attribute10                       varchar2(150),
56   attribute11                       varchar2(150),
57   attribute12                       varchar2(150),
58   attribute13                       varchar2(150),
59   attribute14                       varchar2(150),
60   attribute15                       varchar2(150),
61   attribute16                       varchar2(150),
62   attribute17                       varchar2(150),
63   attribute18                       varchar2(150),
64   attribute19                       varchar2(150),
65   attribute20                       varchar2(150),
66   object_version_number             number(9)
67   );
68 --
69 -- ----------------------------------------------------------------------------
70 -- |           Global Definitions - Internal Development Use Only             |
71 -- ----------------------------------------------------------------------------
72 --
73 g_old_rec  g_rec_type;                            -- Global record definition
74 --
75 --
76 -- ----------------------------------------------------------------------------
77 -- |---------------------------< constraint_error >---------------------------|
78 -- ----------------------------------------------------------------------------
79 -- {Start Of Comments}
80 --
81 -- Description:
82 --   This procedure is called when a constraint has been violated (i.e.
83 --   The exception hr_api.check_integrity_violated,
84 --   hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
85 --   hr_api.unique_integrity_violated has been raised).
86 --   The exceptions can only be raised as follows:
87 --   1) A check constraint can only be violated during an INSERT or UPDATE
88 --      dml operation.
89 --   2) A parent integrity constraint can only be violated during an
90 --      INSERT or UPDATE dml operation.
91 --   3) A child integrity constraint can only be violated during an
92 --      DELETE dml operation.
93 --   4) A unique integrity constraint can only be violated during INSERT or
94 --      UPDATE dml operation.
95 --
96 -- Prerequisites:
97 --   1) Either hr_api.check_integrity_violated,
98 --      hr_api.parent_integrity_violated, hr_api.child_integrity_violated or
99 --      hr_api.unique_integrity_violated has been raised with the subsequent
100 --      stripping of the constraint name from the generated error message
101 --      text.
102 --   2) Standalone validation test which corresponds with a constraint error.
103 --
104 -- In Parameter:
105 --   p_constraint_name is in upper format and is just the constraint name
106 --   (e.g. not prefixed by brackets, schema owner etc).
107 --
108 -- Post Success:
109 --   Development dependant.
110 --
111 -- Post Failure:
112 --   Developement dependant.
113 --
114 -- Developer Implementation Notes:
115 --   For each constraint being checked the hr system package failure message
116 --   has been generated as a template only. These system error messages should
117 --   be modified as required (i.e. change the system failure message to a user
118 --   friendly defined error message).
119 --
120 -- Access Status:
121 --   Internal Development Use Only.
122 --
123 -- {End Of Comments}
124 -- ----------------------------------------------------------------------------
125 Procedure constraint_error
126             (p_constraint_name in all_constraints.constraint_name%TYPE);
127 --
128 -- ----------------------------------------------------------------------------
129 -- |-----------------------------< api_updating >-----------------------------|
130 -- ----------------------------------------------------------------------------
131 -- {Start Of Comments}
132 --
133 -- Description:
134 --   This function is used to populate the g_old_rec record with the
135 --   current row from the database for the specified primary key
136 --   provided that the primary key exists and is valid and does not
137 --   already match the current g_old_rec. The function will always return
138 --   a TRUE value if the g_old_rec is populated with the current row.
139 --   A FALSE value will be returned if all of the primary key arguments
140 --   are null.
141 --
142 -- Prerequisites:
143 --   None.
144 --
145 -- In Parameters:
146 --
147 -- Post Success:
148 --   A value of TRUE will be returned indiciating that the g_old_rec
149 --   is current.
150 --   A value of FALSE will be returned if all of the primary key arguments
151 --   have a null value (this indicates that the row has not be inserted into
152 --   the Schema), and therefore could never have a corresponding row.
153 --
154 -- Post Failure:
155 --   A failure can only occur under two circumstances:
156 --   1) The primary key is invalid (i.e. a row does not exist for the
157 --      specified primary key values).
158 --   2) If an object_version_number exists but is NOT the same as the current
159 --      g_old_rec value.
160 --
161 -- Developer Implementation Notes:
162 --   None.
163 --
164 -- Access Status:
165 --   Internal Development Use Only.
166 --
167 -- {End Of Comments}
168 -- ----------------------------------------------------------------------------
169 Function api_updating
170   (
171   p_ptx_extra_info_id                  in number,
172   p_object_version_number              in number
173   )      Return Boolean;
174 --
175 -- ----------------------------------------------------------------------------
176 -- |---------------------------------< lck >----------------------------------|
177 -- ----------------------------------------------------------------------------
178 -- {Start Of Comments}
179 --
180 -- Description:
181 --   The Lck process has two main functions to perform. Firstly, the row to be
182 --   updated or deleted must be locked. The locking of the row will only be
183 --   successful if the row is not currently locked by another user.
184 --   Secondly, during the locking of the row, the row is selected into
185 --   the g_old_rec data structure which enables the current row values from the
186 --   server to be available to the api.
187 --
188 -- Prerequisites:
189 --   When attempting to call the lock the object version number (if defined)
190 --   is mandatory.
191 --
192 -- In Parameters:
193 --   The arguments to the Lck process are the primary key(s) which uniquely
194 --   identify the row and the object version number of row.
195 --
196 -- Post Success:
197 --   On successful completion of the Lck process the row to be updated or
198 --   deleted will be locked and selected into the global data structure
199 --   g_old_rec.
200 --
201 -- Post Failure:
202 --   The Lck process can fail for three reasons:
203 --   1) When attempting to lock the row the row could already be locked by
204 --      another user. This will raise the HR_Api.Object_Locked exception.
205 --   2) The row which is required to be locked doesn't exist in the HR Schema.
206 --      This error is trapped and reported using the message name
207 --      'HR_7220_INVALID_PRIMARY_KEY'.
208 --   3) The row although existing in the HR Schema has a different object
209 --      version number than the object version number specified.
210 --      This error is trapped and reported using the message name
211 --      'HR_7155_OBJECT_INVALID'.
212 --
213 -- Developer Implementation Notes:
214 --   For each primary key and the object version number arguments add a
215 --   call to hr_api.mandatory_arg_error procedure to ensure that these
216 --   argument values are not null.
217 --
218 -- Access Status:
219 --   Internal Development Use Only.
220 --
221 -- {End Of Comments}
222 -- ----------------------------------------------------------------------------
223 Procedure lck
224   (
225   p_ptx_extra_info_id                  in number,
226   p_object_version_number              in number
227   );
228 --
229 -- ----------------------------------------------------------------------------
230 -- |-----------------------------< convert_args >-----------------------------|
231 -- ----------------------------------------------------------------------------
232 -- {Start Of Comments}
233 --
234 -- Description:
235 --   This function is used to turn attribute parameters into the record
236 --   structure parameter g_rec_type.
237 --
238 -- Prerequisites:
239 --   This is a private function and can only be called from the ins or upd
240 --   attribute processes.
241 --
242 -- In Parameters:
243 --
244 -- Post Success:
245 --   A returning record structure will be returned.
246 --
247 -- Post Failure:
248 --   No direct error handling is required within this function. Any possible
249 --   errors within this function will be a PL/SQL value error due to conversion
250 --   of datatypes or data lengths.
251 --
252 -- Developer Implementation Notes:
253 --   None.
254 --
255 -- Access Status:
256 --   Internal Row Handler Use Only.
257 --
258 -- {End Of Comments}
259 -- ----------------------------------------------------------------------------
260 Function convert_args
261 	(
262 	p_ptx_extra_info_id             in number,
263 	p_information_type              in varchar2,
264 	p_position_transaction_id       in number,
265         p_position_extra_info_id        in number,
266 	p_information_category          in varchar2,
267 	p_information1                  in varchar2,
268 	p_information2                  in varchar2,
269 	p_information3                  in varchar2,
270 	p_information4                  in varchar2,
271 	p_information5                  in varchar2,
272 	p_information6                  in varchar2,
273 	p_information7                  in varchar2,
274 	p_information8                  in varchar2,
275 	p_information9                  in varchar2,
276 	p_information10                 in varchar2,
277 	p_information11                 in varchar2,
278 	p_information12                 in varchar2,
279 	p_information13                 in varchar2,
280 	p_information14                 in varchar2,
281 	p_information15                 in varchar2,
282 	p_information16                 in varchar2,
283 	p_information17                 in varchar2,
284 	p_information18                 in varchar2,
285 	p_information19                 in varchar2,
286 	p_information20                 in varchar2,
287 	p_information21                 in varchar2,
288 	p_information22                 in varchar2,
289 	p_information23                 in varchar2,
290 	p_information24                 in varchar2,
291 	p_information25                 in varchar2,
292 	p_information26                 in varchar2,
293 	p_information27                 in varchar2,
294 	p_information28                 in varchar2,
295 	p_information29                 in varchar2,
296 	p_information30                 in varchar2,
297 	p_attribute_category            in varchar2,
298 	p_attribute1                    in varchar2,
299 	p_attribute2                    in varchar2,
300 	p_attribute3                    in varchar2,
301 	p_attribute4                    in varchar2,
302 	p_attribute5                    in varchar2,
303 	p_attribute6                    in varchar2,
304 	p_attribute7                    in varchar2,
305 	p_attribute8                    in varchar2,
306 	p_attribute9                    in varchar2,
307 	p_attribute10                   in varchar2,
308 	p_attribute11                   in varchar2,
309 	p_attribute12                   in varchar2,
310 	p_attribute13                   in varchar2,
311 	p_attribute14                   in varchar2,
312 	p_attribute15                   in varchar2,
313 	p_attribute16                   in varchar2,
314 	p_attribute17                   in varchar2,
315 	p_attribute18                   in varchar2,
316 	p_attribute19                   in varchar2,
317 	p_attribute20                   in varchar2,
318 	p_object_version_number         in number
319 	)
320 	Return g_rec_type;
321 --
322 end pqh_pte_shd;