1: package body ALR_ACTION_SET_OUTPUTS_PKG as
2: /* $Header: ALRASOTB.pls 120.4.12010000.1 2008/07/27 06:58:31 appldev ship $ */
3: procedure INSERT_ROW (
4: X_ROWID in out nocopy VARCHAR2,
5: X_APPLICATION_ID in NUMBER,
13: X_LAST_UPDATE_DATE in DATE,
14: X_LAST_UPDATED_BY in NUMBER,
15: X_LAST_UPDATE_LOGIN in NUMBER
16: ) is
17: cursor C is select ROWID from ALR_ACTION_SET_OUTPUTS
18: where APPLICATION_ID = X_APPLICATION_ID
19: and ALERT_ID = X_ALERT_ID
20: and ACTION_SET_ID = X_ACTION_SET_ID
21: and NAME = X_NAME
20: and ACTION_SET_ID = X_ACTION_SET_ID
21: and NAME = X_NAME
22: ;
23: begin
24: insert into ALR_ACTION_SET_OUTPUTS (
25: APPLICATION_ID,
26: ACTION_SET_ID,
27: NAME,
28: ALERT_ID,
102: and name = X_NAME;
103:
104: select last_updated_by, last_update_date
105: into db_luby, db_ludate
106: from ALR_ACTION_SET_OUTPUTS
107: where application_id = l_app_id
108: and alert_id = l_alert_id
109: and action_set_id = l_action_set_id
110: and name = X_ACTION_SET_OUTPUT_NAME;
111:
112: if (fnd_load_util.upload_test(f_luby, f_ludate, db_luby,db_ludate,
113: x_custom_mode)) then
114:
115: ALR_ACTION_SET_OUTPUTS_PKG.UPDATE_ROW(
116: X_APPLICATION_ID => l_app_id,
117: X_ALERT_ID => l_alert_id,
118: X_ACTION_SET_ID => l_action_set_id,
119: X_NAME => X_ACTION_SET_OUTPUT_NAME,
128: exception
129:
130: when NO_DATA_FOUND then
131:
132: ALR_ACTION_SET_OUTPUTS_PKG.INSERT_ROW(
133: X_ROWID => l_row_id,
134: X_APPLICATION_ID => l_app_id,
135: X_ALERT_ID => l_alert_id,
136: X_ACTION_SET_ID => l_action_set_id,
159: APPLICATION_ID,
160: ALERT_ID,
161: ACTION_SET_ID,
162: NAME
163: from ALR_ACTION_SET_OUTPUTS
164: where APPLICATION_ID = X_APPLICATION_ID
165: and ALERT_ID = X_ALERT_ID
166: and ACTION_SET_ID = X_ACTION_SET_ID
167: and NAME = X_NAME
196: X_LAST_UPDATED_BY in NUMBER,
197: X_LAST_UPDATE_LOGIN in NUMBER
198: ) is
199: begin
200: update ALR_ACTION_SET_OUTPUTS set
201: SEQUENCE = X_SEQUENCE,
202: SUPPRESS_FLAG = X_SUPPRESS_FLAG,
203: APPLICATION_ID = X_APPLICATION_ID,
204: ALERT_ID = X_ALERT_ID,
223: X_ACTION_SET_ID in NUMBER,
224: X_NAME in VARCHAR2
225: ) is
226: begin
227: delete from ALR_ACTION_SET_OUTPUTS
228: where APPLICATION_ID = X_APPLICATION_ID
229: and ALERT_ID = X_ALERT_ID
230: and ACTION_SET_ID = X_ACTION_SET_ID
231: and NAME = X_NAME;
236:
237: end DELETE_ROW;
238:
239:
240: end ALR_ACTION_SET_OUTPUTS_PKG;