DBA Data[Home] [Help]

PACKAGE: APPS.GMP_RESOURCE_DTL_PUB

Source


1 PACKAGE GMP_RESOURCE_DTL_PUB AUTHID CURRENT_USER AS
2 /* $Header: GMPRSDTS.pls 120.7.12020000.2 2012/07/24 15:18:36 vkinduri ship $ */
3 /*#
4  * This is the public interface for OPM Plant Resources API
5  * These API can be used  for creation, updation or deletion of Plant
6  * Resources in OPM
7  * @rep:scope public
8  * @rep:product GMP
9  * @rep:displayname GMP_RESOURCE_DTL_PUB
10  * @rep:lifecycle active
11  * @rep:category BUSINESS_ENTITY GMP_PLANT_RESOURCE
12 */
13 
14   m_api_version   CONSTANT NUMBER         := 1;
15   m_pkg_name      CONSTANT VARCHAR2 (30)  := 'GMP_RESOURCE_DTL_PUB';
16   v_update_flag  varchar2(1) := 'N';
17 
18   /* Define record and table type */
19   TYPE update_table_rec_type IS RECORD
20   (
21    p_col_to_update	VARCHAR2(30)
22   ,p_value		VARCHAR2(30)
23   );
24 
25   TYPE update_tbl_type IS TABLE OF update_table_rec_type
26        INDEX BY BINARY_INTEGER;
27 
28   TYPE resource_instances_rec IS RECORD
29   (
30      RESOURCE_ID                     NUMBER,
31      INSTANCE_ID                     NUMBER,
32      INSTANCE_NUMBER                 NUMBER,
33      VENDOR_ID                       NUMBER,
34      MODEL_NUMBER                    VARCHAR2(30),
35      SERIAL_NUMBER                   VARCHAR2(30),
36      TRACKING_NUMBER                 VARCHAR2(30),
37      EFF_START_DATE                  DATE,
38      EFF_END_DATE                    DATE,
39      LAST_MAINTENANCE_DATE           DATE,
40      MAINTENANCE_INTERVAL            NUMBER,
41      INACTIVE_IND                    NUMBER,
42      CALIBRATION_FREQUENCY           NUMBER,
43      CALIBRATION_PERIOD              VARCHAR2(4),
44      CALIBRATION_ITEM_ID             NUMBER,
45      LAST_CALIBRATION_DATE           DATE,
46      NEXT_CALIBRATION_DATE           DATE,
47      LAST_CERTIFICATION_DATE         DATE,
48      CERTIFIED_BY                    VARCHAR2(32),
49      CREATION_DATE                   DATE,
50      CREATED_BY                      NUMBER,
51      LAST_UPDATE_DATE                DATE,
52      LAST_UPDATED_BY                 NUMBER,
53      LAST_UPDATE_LOGIN               NUMBER
54   ) ;
55 
56   TYPE resource_instances_tbl IS TABLE OF resource_instances_rec
57        INDEX BY BINARY_INTEGER;
58 
59 /*#
60  *  API for INSERT_RESOURCE_DTL
61  *  This API to craete a new plant resource i.e. to insert a row in the plant
62  *  resource table - cr_rsrc_dtl
63  *  @param p_api_version Version Number of the API
64  *  @param p_init_msg_list Flag for initializing message list BOOLEAN
65  *  @param p_commit   This is the commmit flag BOOLEAN.
66  *  @param p_resources This is the information about the resource to be created
67  *  in the prescribed format - row type of cr_rsrc_dtl table.
68  *  @param p_rsrc_instances This is the information about the instances of the
69  *  resource being created
70  *  @param x_message_count Number of messages on message stack
71  *  @param x_message_list  Actual message data from message stack
72  *  @param x_return_status Return status 'S'-Success, 'E'-Error,
73  *       'U'-Unexpected Error
74  *  @rep:scope public
75  *  @rep:lifecycle active
76  *  @rep:displayname INSERT_RESOURCE_DTL
77 */
78  PROCEDURE insert_resource_dtl
79   ( p_api_version            IN   NUMBER                :=  1
80   , p_init_msg_list          IN   BOOLEAN               :=  TRUE
81   , p_commit                 IN   BOOLEAN               :=  FALSE
82   , p_resources              IN   cr_rsrc_dtl%ROWTYPE
83   , p_rsrc_instances         IN   resource_instances_tbl
84   , x_message_count          OUT  NOCOPY NUMBER
85   , x_message_list           OUT  NOCOPY VARCHAR2
86   , x_return_status          IN OUT  NOCOPY VARCHAR2
87   ) ;
88 
89 /*#
90  *  API for CHECK_DATA
91  *  This API to validate the resource data before updating or creating a plant
92  *  resource.
93  *  @param p_organization_id This is the  Inventory Organization to which the Resource is Associated
94  *  @param p_resources This is the Resource that need to be inserted into the
95  *  table.
96  *  @param p_resource_id This is the resource id of the resource that will be passed
97  *  @param p_group_resource Resource Group - Resource can be grouped by this
98  *  type
99  *  @param p_assigned_qty    How many of the resources are in the plant
100  *  @param p_daily_avl_use   Number of hours the resource is available in the
101  *  plant each day
102  *  @param p_usage_um       Unit of measure for measuring resource usage
103  *  @param p_nominal_cost    Cost of the Resource in the Plant
104  *  @param p_inactive_ind    Inactive indicator. 0=Active, 1=Inactive
105  *  @param p_ideal_capacity    Ideal Capacity of the Resource
106  *  @param p_min_capacity    Minimum Capacity of the Resource
107  *  @param p_max_capacity    Maximum Capacity of the Resource
108  *  @param p_capacity_uom    Resource Capacity Uom
109  *  @param p_capacity_constraint  Resource Capacity Constraint
110  *  @param p_capacity_tolerance  Capacity Tolerance
111  *  @param p_schedule_ind  Schedule Indicator This Column is used to define
112  *  whether a resource is should be Scheduled or Not, the Values are 1=
113  *  Scheduling , 2= Schedule to Instance, 0= Do Not Schedule
114  *  @param p_utilization    Indicates the resource Utilization
115  *  @param p_efficiency     Indicates the resource Efficiency
116  *  @param p_calendar_code  Indicates the calendar code
117  *  @param x_message_count Number of messages on message stack
118  *  @param x_message_list  Actual message data from message stack
119  *  @param x_return_status Return status 'S'-Success, 'E'-Error,
120  *       'U'-Unexpected Error
121  *  @rep:scope public
122  *  @rep:lifecycle active
123  *  @rep:displayname CHECK_DATA
124 */
125  PROCEDURE  check_data
126   (
127     p_organization_id      IN   NUMBER, /* B4724360 - INVCONV */
128     p_resources            IN   VARCHAR2,
129     p_resource_id          IN   NUMBER, /* B4724360 - INVCONV */
130     p_group_resource       IN   VARCHAR2,
131     p_assigned_qty         IN   integer,
132     p_daily_avl_use        IN   NUMBER,
133     p_usage_um             IN   VARCHAR2,
134     p_nominal_cost         IN   NUMBER,
135     p_inactive_ind         IN   NUMBER,
136     p_ideal_capacity       IN   NUMBER,
137     p_min_capacity         IN   NUMBER,
138     p_max_capacity         IN   NUMBER,
139     p_capacity_uom         IN   VARCHAR2,
140     p_capacity_constraint  IN   NUMBER,
141     p_capacity_tolerance   IN   NUMBER,
142     p_schedule_ind         IN   NUMBER,
143     p_utilization          IN   NUMBER,
144     p_efficiency           IN   NUMBER,
145     p_calendar_code        IN   VARCHAR2, /* B4724360 - INVCONV */
146     p_batchable_flag       IN   NUMBER,
147     p_batch_window         IN   NUMBER,
148     x_message_count        OUT  NOCOPY NUMBER,
149     x_message_list         OUT  NOCOPY VARCHAR2,
150     x_return_status        OUT  NOCOPY VARCHAR2
151  );
152 
153 /*#
154  *  API for INSERT_DETAIL_ROWS
155  *  This API inserts a row in Plant Resource table (cr_rsrc_dtl)
156  *  @param p_organization_id This is the Inventory Organization to which the Resource is Associated
157  *  @param p_resources This is the Resource that needs to be inserted into the
158  *  table.
159  *  @param p_group_resource Resource Group - Resource can be grouped by this
160  *  type
161  *  @param p_assigned_qty    How many of the resources are in the plant
162  *  @param p_daily_avail_use   Number of hours the resource is available in the
163  *  plant each day
164  *  @param p_usage_um       Unit of measure for measuring resource usage
165  *  @param p_nominal_cost    Cost of the Resource in the Plant
166  *  @param p_inactive_ind    Inactive indicator. 0=Active, 1=Inactive
167  *  @param p_creation_date   Row Who columns
168  *  @param p_created_by      Row Who columns
169  *  @param p_last_update_date      Row Who columns
170  *  @param p_last_updated_by       Row Who columns
171  *  @param p_last_update_login       Row Who columns
172  *  @param p_trans_cnt       Not currently used
173  *  @param p_delete_mark     Standard: 0=Active record (default); 1=Marked for
174  *  (logical) deletion
175  *  @param p_text_code   ID which joins any rows of text in this table to the
176  *  Text Table for this Module
177  *  @param p_ideal_capacity    Ideal Capacity of the Resource
178  *  @param p_min_capacity    Minimum Capacity of the Resource
179  *  @param p_max_capacity    Maximum Capacity of the Resource
180  *  @param p_capacity_uom    Resource Capacity Uom
181  *  @param p_resource_id   Unique Identifier of the Resource Surrogate Key
182  *  @param p_capacity_constraint  Resource Capacity Constraint
183  *  @param p_capacity_tolerance  Capacity Tolerance
184  *  @param p_schedule_ind  Schedule Indicator This Column is used to define
185  *  whether a resource is should be Scheduled or Not, the Values are 1=
186  *  Scheduling , 2= Schedule to Instance, 0= Do Not Schedule
187  *  @param p_utilization    Indicates the resource Utilization
188  *  @param p_efficiency     Indicates the resource Efficiency
189  *  @param p_calendar_code  Indicates the calendar code
190  *  @rep:scope public
191  *  @rep:lifecycle active
192  *  @rep:displayname INSERT_DETAIL_ROWS
193 */
194 --Bug#6413873 Need to pass planning_exception_set
195 PROCEDURE  insert_detail_rows
196   (
197      p_organization_id        IN  NUMBER, /* B4724360 - INVCONV */
198      p_resources              IN  varchar2,
199      p_group_resource         IN  VARCHAR2,
200      p_assigned_qty           IN  NUMBER,
201      p_daily_avail_use        IN  NUMBER,
202      p_usage_um               IN  VARCHAR2,
203      p_nominal_cost           IN  NUMBER,
204      p_inactive_ind           IN  NUMBER,
205      p_creation_date          IN  DATE,
206      p_created_by             IN  NUMBER,
207      p_last_update_date       IN  DATE,
208      p_last_updated_by        IN  NUMBER,
209      p_last_update_login      IN  NUMBER,
210      p_trans_cnt              IN  NUMBER,
211      p_delete_mark            IN  NUMBER,
212      p_text_code              IN  NUMBER,
213      p_ideal_capacity         IN  NUMBER,
214      p_min_capacity           IN  NUMBER,
215      p_max_capacity           IN  NUMBER,
216      p_capacity_uom           IN  VARCHAR2,
217      p_resource_id            IN  NUMBER,
218      p_capacity_constraint    IN  NUMBER,
219      p_capacity_tolerance     IN  NUMBER,
220      p_schedule_ind           IN  NUMBER,
221      p_utilization            IN  NUMBER,
222      p_efficiency             IN  NUMBER,
223      p_planning_exception_set IN  VARCHAR2,    /*Bug#6413873 KBANDDYO*/
224      p_calendar_code          IN  VARCHAR2, /* B4724360 - INVCONV */
225      p_sds_window             IN  NUMBER ,  /* B7637373 - VPEDARLA */
226      p_batchable_flag         IN  NUMBER,
227      p_batch_window           IN  NUMBER
228   );
229 
230 /*#
231  *  API for UPDATE_RESOURCE_DTL
232  *  This API updates a Plant Resource ie. a row in table cr_rsrc_dtl.
233  *  @param p_api_version Version Number of the API
234  *  @param p_init_msg_list Flag for initializing message list BOOLEAN
235  *  @param p_commit   This is the commmit flag BOOLEAN.
236  *  @param p_resources This is the resource information that needs to be updated
237  *  @param x_message_count Number of messages on message stack
238  *  @param x_message_list  Actual message data from message stack
239  *  @param x_return_status Return status 'S'-Success, 'E'-Error,
240  *       'U'-Unexpected Error
241  *  @rep:scope public
242  *  @rep:lifecycle active
243  *  @rep:displayname UPDATE_RESOURCE_DTL
244 */
245 
246 PROCEDURE update_resource_dtl
247   ( p_api_version            IN   NUMBER               :=  1
248   , p_init_msg_list          IN   BOOLEAN              :=  TRUE
249   , p_commit                 IN   BOOLEAN              :=  FALSE
250   , p_resources              IN   cr_rsrc_dtl%ROWTYPE
251   , x_message_count          OUT  NOCOPY NUMBER
252   , x_message_list           OUT  NOCOPY VARCHAR2
253   , x_return_status          OUT  NOCOPY VARCHAR2
254   ) ;
255 
256 /*#
257  *  API for UPDATE_DETAIL_ROWS
258  *  This API updates a row in  Plant Resource table (cr_rsrc_dtl)
259  *  @param p_organization_id This is the Inventory Organization to which the Resource is Associated
260  *  @param p_resources This is the Resource that is to be updated .
261  *  @param p_group_resource Resource Group - Resource can be grouped by this
262  *  type
263  *  @param p_assigned_qty    How many of the resources are in the plant
264  *  @param p_daily_avail_use   Number of hours the resource is available in the
265  *  plant each day
266  *  @param p_usage_um       Unit of measure in which daily_avail_use is
267  *  expressed
268  *  @param p_nominal_cost    Cost of the Resource in the Plant
269  *  @param p_inactive_ind    Inactive indicator. 0=Active, 1=Inactive
270  *  @param p_creation_date   Row Who columns
271  *  @param p_created_by      Row Who columns
272  *  @param p_last_update_date      Row Who columns
273  *  @param p_last_updated_by       Row Who columns
274  *  @param p_last_update_login       Row Who columns
275  *  @param p_trans_cnt       Not currently used
279  *  Text Table for this Module
276  *  @param p_delete_mark     Standard: 0=Active record (default); 1=Marked for
277  *  (logical) deletion
278  *  @param p_text_code   ID which joins any rows of text in this table to the
280  *  @param p_ideal_capacity    Ideal Capacity of the Resource
281  *  @param p_min_capacity    Minimum Capacity of the Resource
282  *  @param p_max_capacity    Maximum Capacity of the Resource
283  *  @param p_capacity_uom    Resource Capacity Uom
284  *  @param p_resource_id   Unique Identifier of the Resource Surrogate Key
285  *  @param p_capacity_constraint  Resource Capacity Constraint
286  *  @param p_capacity_tolerance  Capacity Tolerance
287  *  @param p_schedule_ind  Schedule Indicator This Column is used to define
288  *  whether a resource is should be Scheduled or Not, the Values are 1=
289  *  Scheduling , 2= Schedule to Instance, 0= Do Not Schedule
290  *  @param p_utilization    Indicates the resource Utilization
291  *  @param p_efficiency     Indicates the resource Efficiency
292  *  @param p_calendar_code  Indicates the calendar code
293  *  @param x_return_status Return status 'S'-Success, 'E'-Error,
294  *       'U'-Unexpected Error
295  *  @rep:scope public
296  *  @rep:lifecycle active
297  *  @rep:displayname UPDATE_DETAIL_ROWS
298 */
299 --Bug#6413873 Need to pass planning_exception_set
300 PROCEDURE  update_detail_rows
301   (
302      p_organization_id        IN  NUMBER, /* B4724360 - INVCONV */
303      p_resources              IN  VARCHAR2,
304      p_group_resource         IN  VARCHAR2,
305      p_assigned_qty           IN  NUMBER,
306      p_daily_avail_use        IN  NUMBER,
307      p_usage_um               IN  VARCHAR2,
308      p_nominal_cost           IN  NUMBER,
309      p_inactive_ind           IN  NUMBER,
310      p_creation_date          IN  DATE,
311      p_created_by             IN  NUMBER,
312      p_last_update_date       IN  DATE,
313      p_last_updated_by        IN  NUMBER,
314      p_last_update_login      IN  NUMBER,
315      p_trans_cnt              IN  NUMBER,
316      p_delete_mark            IN  NUMBER,
317      p_text_code              IN  NUMBER,
318      p_ideal_capacity         IN  NUMBER,
319      p_min_capacity           IN  NUMBER,
320      p_max_capacity           IN  NUMBER,
321      p_capacity_uom           IN  VARCHAR2,
322      p_resource_id            IN  NUMBER,
323      p_capacity_constraint    IN  NUMBER,
324      p_capacity_tolerance     IN  NUMBER,
325      p_schedule_ind           IN  NUMBER,
326      p_utilization            IN  NUMBER,
327      p_efficiency             IN  NUMBER,
328      p_sds_window             IN  NUMBER,   /* B7637373 - VPEDARLA */
329      p_planning_exception_set IN  VARCHAR2,    /*Bug#6413873 KBANDDYO*/
330      p_calendar_code          IN  VARCHAR2, /* B4724360 - INVCONV */
331      p_batchable_flag         IN  NUMBER,
332      p_batch_window           IN  NUMBER ,
333      x_return_status          OUT NOCOPY VARCHAR2
334   ) ;
335 
336 /*#
337  *  API for DELETE_RESOURCES
338  *  This API Deletes a row in  Plant Resource table (cr_rsrc_dtl)
339  *  @param p_api_version Version Number of the API
340  *  @param p_init_msg_list Flag for initializing message list BOOLEAN
341  *  @param p_commit   This is the commmit flag BOOLEAN.
342  *  @param p_organization_id This is the Inventory Organization to which the Resource is Associated
343  *  @param p_resources This is the resource information that needs to be Deleted
344  *  @param x_message_count Number of messages on message stack
345  *  @param x_message_list  Actual message data from message stack
346  *  @param x_return_status Return status 'S'-Success, 'E'-Error,
347  *       'U'-Unexpected Error
348  *  @rep:scope public
349  *  @rep:lifecycle active
350  *  @rep:displayname DELETE_RESOURCES
351 */
352 PROCEDURE delete_resources
353   ( p_api_version 	IN NUMBER 	:= 1
354   , p_init_msg_list 	IN BOOLEAN 	:= TRUE
355   , p_commit		IN BOOLEAN 	:= FALSE
356   , p_organization_id 	IN cr_rsrc_dtl.organization_id%TYPE
357   , p_resources 	IN cr_rsrc_dtl.resources%TYPE
358   , x_message_count 	OUT NOCOPY NUMBER
359   , x_message_list 	OUT NOCOPY VARCHAR2
360   , x_return_status	OUT NOCOPY VARCHAR2
361   );
362 
363 /*#
364  *  API for CHECK_INSTANCE_DATA
365  *  This API checks the Instance data before Insertion
366  *  @param p_resource_id   Unique Identifier of the Resource Surrogate Key
367  *  @param p_instance_id   Surrogate Key to uniquely identify the Instance
368  *  @param p_vendor_id     Surrogate Key to uniquely identify the Vendor
369  *  @param p_eff_start_date  The Start Date for the Resource when it becomes
370  *  Active
371  *  @param p_eff_end_date  The End Date for the Resource till it is Active
372  *  @param p_maintenance_interval  The number of Days from the last time
373  *  maintenance was done where maintenance should occur again
374  *  @param p_inactive_ind    Inactive indicator. 0=Active, 1=Inactive
375  *  @param p_calibration_frequency  Resource Calibration Frequency
376  *  @param p_calibration_item_id  The Item with which the Calibration is done
377  *  @param x_message_count Number of messages on message stack
378  *  @param x_message_list  Actual message data from message stack
379  *  @param x_return_status Return status 'S'-Success, 'E'-Error,
380  *       'U'-Unexpected Error
381  *  @rep:scope public
382  *  @rep:lifecycle active
383  *  @rep:displayname CHECK_INSTANCE_DATA
384 */
385 PROCEDURE  check_instance_data
386   (
387      p_resource_id             IN NUMBER
388     ,p_instance_id             IN NUMBER
389     ,p_vendor_id               IN NUMBER
390     ,p_eff_start_date          IN DATE
391     ,p_eff_end_date            IN DATE
392     ,p_maintenance_interval    IN NUMBER
393     ,p_inactive_ind            IN NUMBER
394     ,p_calibration_frequency   IN NUMBER
395     ,p_calibration_item_id     IN NUMBER
399     ) ;
396     ,x_message_count           OUT  NOCOPY NUMBER
397     ,x_message_list            OUT  NOCOPY VARCHAR2
398     ,x_return_status           OUT  NOCOPY VARCHAR2
400 
401 /*#
402  *  API for INSERT_RESOURCE_INSTANCE
403  *  This API inserts a row in Plant Resource Instance table
404  *  (gmp_resource_instances)
405  *  @param p_resource_id   Unique Identifier of the Resource Surrogate Key
406  *  @param p_instance_id   Surrogate Key to uniquely identify the Instance
407  *  @param p_instance_number   The number identifying the resource uniquely
408  *  @param p_vendor_id     Surrogate Key to uniquely identify the Vendor
409  *  @param p_model_number the Model number from the manufacturer for the
410  *  resource
411  *  @param p_serial_number the Combination of numbers, Letters and Symbols the
412  *  manufacturer uses to identify the resource
413  *  @param p_tracking_number the unique combination of numbers, Letters and
414  *  symbols to identify the resource for internal tracking
415  *  @param p_eff_start_date  The Start Date for the Resource when it becomes
416  *  Active
417  *  @param p_eff_end_date  The End Date for the Resource till it is Active
418  *  @param p_last_maintenance_date  The Date maintenance last occurred for the
419  *  resource
420  *  @param p_maintenance_interval The number of Days from the last time
421  *  maintenance was done where maintenance should occur again
422  *  @param p_inactive_ind    Inactive indicator. 0=Active, 1=Inactive
423  *  @param p_calibration_frequency  Resource Calibration Frequency
424  *  @param p_calibration_period  Resource Calibration Period
425  *  @param p_calibration_item_id  The Item with which the Calibration is done
426  *  @param p_last_calibration_date Standard date validation
427  *  @param p_next_calibration_date Standard date validation
428  *  @param p_last_certification_date  Standard date validation
429  *  @param p_certified_by Person Who has done the Calibration Certification
430  *  @param p_creation_date   Row Who columns
431  *  @param p_created_by      Row Who columns
432  *  @param p_last_update_date      Row Who columns
433  *  @param p_last_updated_by       Row Who columns
434  *  @param p_last_update_login       Row Who columns
435  *  @rep:scope public
436  *  @rep:lifecycle active
437  *  @rep:displayname INSERT_RESOURCE_INSTANCE
438 */
439 PROCEDURE  insert_resource_instance (
440      p_resource_id                     IN NUMBER
441     ,p_instance_id                     IN NUMBER
442     ,p_instance_number                 IN NUMBER
443     ,p_vendor_id                       IN NUMBER
444     ,p_model_number                    IN VARCHAR2
445     ,p_serial_number                   IN VARCHAR2
446     ,p_tracking_number                 IN VARCHAR2
447     ,p_eff_start_date                  IN DATE
448     ,p_eff_end_date                    IN DATE
449     ,p_last_maintenance_date           IN DATE
450     ,p_maintenance_interval            IN NUMBER
451     ,p_inactive_ind                    IN NUMBER
452     ,p_calibration_frequency           IN NUMBER
453     ,p_calibration_period              IN VARCHAR2
454     ,p_calibration_item_id             IN NUMBER
455     ,p_last_calibration_date           IN DATE
456     ,p_next_calibration_date           IN DATE
457     ,p_last_certification_date         IN DATE
458     ,p_certified_by                    IN VARCHAR2
459     ,p_creation_date                   IN DATE
460     ,p_created_by                      IN NUMBER
461     ,p_last_update_date                IN DATE
462     ,p_last_updated_by                 IN NUMBER
463     ,p_last_update_login               IN NUMBER );
464 
465 /*#
466  *  API for UPDATE_INSTANCES
467  *  This API updates a Resource Instance Table ie. a row in table
468  *  gmp_resource_instances.
469  *  @param p_api_version Version Number of the API
470  *  @param p_init_msg_list Flag for initializing message list BOOLEAN
471  *  @param p_commit   This is the commmit flag BOOLEAN.
472  *  @param p_instances This is the Instances of the Resource that need to be
473  *  updated
474  *  @param x_message_count Number of messages on message stack
475  *  @param x_message_list  Actual message data from message stack
476  *  @param x_return_status Return status 'S'-Success, 'E'-Error,
477  *       'U'-Unexpected Error
478  *  @rep:scope public
479  *  @rep:lifecycle active
480  *  @rep:displayname UPDATE_INSTANCES
481 */
482 PROCEDURE update_instances
483   ( p_api_version            IN   NUMBER         :=  1
484   , p_init_msg_list          IN   BOOLEAN        :=  TRUE
485   , p_commit                 IN   BOOLEAN        :=  FALSE
486   , p_instances              IN   gmp_resource_instances%ROWTYPE
487   , x_message_count          OUT  NOCOPY NUMBER
488   , x_message_list           OUT  NOCOPY VARCHAR2
489   , x_return_status          OUT  NOCOPY VARCHAR2
490   ) ;
491 
492 /*#
493  *  API for UPDATE_INSTANCE_ROW
494  *  This API updates a row in Resource Instance Table ie.  gmp_resource_instances.
495  *  @param p_resource_id   Unique Identifier of the Resource Surrogate Key
496  *  @param p_instance_id   Surrogate Key to uniquely identify the Instance
497  *  @param p_instance_number   The number identifying the resource uniquely
498  *  @param p_vendor_id     Surrogate Key to uniquely identify the Vendor
499  *  @param p_model_number the Model number from the manufacturer for the
500  *  resource
501  *  @param p_serial_number the Combination of numbers, Letters and Symbols the
502  *  manufacturer uses to identify the resource
503  *  @param p_tracking_number the unique combination of numbers, Letters and
504  *  symbols to identify the resource for internal tracking
505  *  @param p_eff_start_date  The Start Date for the Resource when it becomes
506  *  Active
507  *  @param p_eff_end_date    The End Date for the Resource till it is Active
508  *  @param p_last_maintenance_date  The Date maintenance last occurred for the
509  *  resource
513  *  @param p_calibration_frequency  Resource Calibration Frequency
510  *  @param p_maintenance_interval The number of Days from the last time
511  *  maintenance was done where maintenance should occur again
512  *  @param p_inactive_ind       Inactive indicator. 0=Active, 1=Inactive
514  *  @param p_calibration_period    Resource Calibration Period
515  *  @param p_calibration_item_id    The Item with which the Calibration is done
516  *  @param p_last_calibration_date    Standard date validation
517  *  @param p_next_calibration_date    Standard date validation
518  *  @param p_last_certification_date    Standard date validation
519  *  @param p_certified_by    Person Who has done the Calibration Certification
520  *  @param p_creation_date   Row Who columns
521  *  @param p_created_by      Row Who columns
522  *  @param p_last_update_date      Row Who columns
523  *  @param p_last_updated_by       Row Who columns
524  *  @param p_last_update_login       Row Who columns
525  *  @param x_return_status Return status 'S'-Success, 'E'-Error,
526  *       'U'-Unexpected Error
527  *  @rep:scope public
528  *  @rep:lifecycle active
529  *  @rep:displayname UPDATE_INSTANCE_ROW
530 */
531 PROCEDURE  update_instance_row
532   (
533      p_resource_id                     IN NUMBER
534     ,p_instance_id                     IN NUMBER
535     ,p_instance_number                 IN NUMBER
536     ,p_vendor_id                       IN NUMBER
537     ,p_model_number                    IN VARCHAR2
538     ,p_serial_number                   IN VARCHAR2
539     ,p_tracking_number                 IN VARCHAR2
540     ,p_eff_start_date                  IN DATE
541     ,p_eff_end_date                    IN DATE
542     ,p_last_maintenance_date           IN DATE
543     ,p_maintenance_interval            IN NUMBER
544     ,p_inactive_ind                    IN NUMBER
545     ,p_calibration_frequency           IN NUMBER
546     ,p_calibration_period              IN VARCHAR2
547     ,p_calibration_item_id             IN NUMBER
548     ,p_last_calibration_date           IN DATE
549     ,p_next_calibration_date           IN DATE
550     ,p_last_certification_date         IN DATE
551     ,p_certified_by                    IN VARCHAR2
552     ,p_creation_date                   IN DATE
553     ,p_created_by                      IN NUMBER
554     ,p_last_update_date                IN DATE
555     ,p_last_updated_by                 IN NUMBER
556     ,p_last_update_login               IN NUMBER
557     ,x_return_status                   OUT  NOCOPY VARCHAR2
558   ) ;
559 
560 END GMP_RESOURCE_DTL_PUB;
561