DBA Data[Home] [Help]

PACKAGE: APPS.AMS_LISTDEDUPE_PVT

Source


1 PACKAGE AMS_ListDedupe_PVT AUTHID CURRENT_USER as
2 /* $Header: amsvldds.pls 115.11 2002/11/12 23:39:04 jieli ship $ */
3 
4 -- Start of Comments
5 --
6 -- NAME
7 --   AMS_ListDedupe_PVT
8 --
9 -- PURPOSE
10 --   This package is a Private API for managing List Deduplication information in
11 --   AMS.  It contains specification for pl/sql records and tables
12 --
13 --   Functions:
14 --	Filte_Word (see below for specification)
15 --	Dedupe_List (see below for specification)
16 --
17 -- NOTES
18 --
19 -- HISTORY
20 --
21 --	06/29/1999	khung		created
22 --	07/22/1999	khung		Changed package name and file name
23 --	09/30/1999	KHUNG		Add support of deduplication from AMS_IMP_SOURCE_LINE
24 --					as list entry table
25 -- 11/11/1999  choang   Moved Generate_Key from AMS_PartyImport_PVT.
26 --
27 -- End of Comments
28 
29 -- global constants
30 
31 /*****************************************************************************************/
32 -- Start of Comments
33 --
34 --    NAME
35 --	Filter_Word
36 
37 --    PURPOSE
38 --	Replaces all noise words for the relevant fields in AMS_LIST_ENTRIES
39 --
40 --    Pre-reqs    : None
41 --    Paramaeters :
42 --    IN		:
43 --		p_word		VARCHAR2
44 --		p_substr_len	AMS_LIST_RULE_ENTRIES.SUBSTRING_LEN%TYPE
45 --		p_table_name	AMS_LIST_RULE_FIELDS.TABLE_NAME%TYPE
46 --		p_column_name	AMS_LIST_RULE_FIELDS.COLUMN_NAME%TYPE
47 --
48 --    NOTES
49 --
50 --
51 --    HISTORY
52 --      06/29/1999	khung		created
53 
54 -- End Of Comments
55 
56 
57 FUNCTION Filter_Word
58  (p_word		VARCHAR2
59  ,p_substr_len		AMS_LIST_RULE_FIELDS.SUBSTRING_LENGTH%TYPE
60  ,p_field_table_name	AMS_LIST_RULE_FIELDS.FIELD_TABLE_NAME%TYPE
61  ,p_field_column_name	AMS_LIST_RULE_FIELDS.FIELD_COLUMN_NAME%TYPE
62  )
63  RETURN VARCHAR2;
64 
65 /*****************************************************************************************/
66 -- Start of Comments
67 --
68 --    NAME
69 --	Dedupe_List
70 
71 --    PURPOSE
72 --	This function is for deduplication
73 --
74 --    Pre-reqs    : None
75 --    Paramaeters :
76 --    IN	  :
77 --		p_list_header_id		AMS_LIST_HEADERS_ALL.LIST_HEADER_ID%TYPE
78 --		p_enable_word_replacement_flag	AMS_LIST_HEADERS_ALL.ENABLE_WORD_REPLACEMENT_FLAG%TYPE
79 --		p_send_to_log			VARCHAR2 := 'N'
80 --
81 --    NOTES
82 --
83 --
84 --    HISTORY
85 --      06/29/1999	khung		created
86 
87 -- End Of Comments
88 
89 
90 FUNCTION Dedupe_List
91  (p_list_header_id			AMS_LIST_HEADERS_ALL.LIST_HEADER_ID%TYPE
92  ,p_enable_word_replacement_flag	AMS_LIST_HEADERS_ALL.ENABLE_WORD_REPLACEMENT_FLAG%TYPE
93  ,p_send_to_log				VARCHAR2 := 'N'
94  --	add by khung@us 09/30/1999	deduping for entries from AMS_IMP_SOURCE_LINE table
95  ,p_object_name				VARCHAR2 := 'AMS_LIST_ENTRIES'
96  )
97  RETURN NUMBER;
98 
99 
100 --------------------------------------------------------------------
101 -- PROCEDURE
102 --    Generate_Key
103 -- PURPOSE
104 --    Return a DEDUPE_KEY given the rules to use
105 --    for generating the key.
106 -- PARAMETERS
107 --    p_list_rule_id: the rule to use for generating the key.
108 --    p_sys_object_id: the ID of the record
109 --    p_sys_object_id_field: the ID field to use in the WHERE
110 --       clause of the dynamic SQL statement.
111 --    p_word_replacement_flag: indicate whether to perform
112 --       word replacement against the data.
113 --    x_dedupe_key: the out value containing the generated key.
114 --------------------------------------------------------------------
115 PROCEDURE Generate_Key (
116    p_api_version        IN    NUMBER,
117    p_init_msg_list      IN    VARCHAR2  := FND_API.g_false,
118    p_validation_level   IN    NUMBER    := FND_API.g_valid_level_full,
119 
120    x_return_status      OUT NOCOPY   VARCHAR2,
121    x_msg_count          OUT NOCOPY   NUMBER,
122    x_msg_data           OUT NOCOPY   VARCHAR2,
123 
124    p_list_rule_id       IN    NUMBER,
125    p_sys_object_id      IN    NUMBER,
126    p_sys_object_id_field   IN    VARCHAR2,
127    p_word_replacement_flag IN    VARCHAR2,
128    x_dedupe_key         OUT NOCOPY   VARCHAR2
129 );
130 
131 
132  FUNCTION Replace_Word(p_word              VARCHAR2,
133                         p_replacement_type  VARCHAR2)
134   RETURN VARCHAR2;
135 
136 END AMS_ListDedupe_PVT;
137