DBA Data[Home] [Help]

PACKAGE: APPS.GR_TOXIC_CALCULATIONS

Source


1 PACKAGE gr_toxic_calculations AUTHID CURRENT_USER AS
2 /* $Header: GRTXCALS.pls 115.1 2002/10/29 19:22:01 mgrosser noship $ */
3 
4 /* This record type will contain the data that was used to calculate the
5    product's toxicity value */
6 TYPE ingredient_values IS RECORD
7   (  item_code            VARCHAR2(240),
8      concentration_pct    NUMBER,
9      weight_pct           NUMBER,
10      toxic_species_code   GR_ITEM_TOXIC.toxic_species_code%TYPE,
11      toxic_dose           NUMBER,
12      toxic_uom            GR_ITEM_TOXIC.toxic_uom%TYPE  );
13 
14 
15 
16 TYPE t_ingredient_values IS TABLE OF ingredient_values
17              INDEX BY BINARY_INTEGER;
18 
19 
20 
21 /* This function is used to derive the products toxic value from the
22    ingredient values */
23 FUNCTION calculate_toxic_value (
24          p_item_code IN  varchar2,        /* Item code of product */
25          p_rollup_type IN  number,        /* The type of toxic calculation */
26          p_label_code  IN varchar2,       /* The toxicity calculation label code */
27          x_ingred_value_tbl OUT NOCOPY GR_TOXIC_CALCULATIONS.t_ingredient_values,
28                                           /*  Table of values used in calculation */
29          x_error_message OUT NOCOPY varchar2,    /* Error message */
30          x_return_status OUT NOCOPY varchar2     /* 'S'uccess, 'E'rror, 'U'nexpected Error */
31          )  RETURN number;
32 
33 
34 END gr_toxic_calculations;
35