The following lines contain the word 'select', 'insert', 'update' or 'delete':
PROCEDURE Insert_Row(
px_chklst_response_id IN OUT NOCOPY NUMBER,
p_checklist_item_id NUMBER,
px_object_version_number IN OUT NOCOPY NUMBER,
p_arc_response_for_entity_code VARCHAR2,
p_response_flag VARCHAR2,
p_response_for_entity_id NUMBER,
p_created_by NUMBER,
p_creation_date DATE,
p_last_updated_by NUMBER,
p_last_update_date DATE,
p_last_update_login NUMBER)
IS
x_rowid VARCHAR2(30);
INSERT INTO pv_ge_chklst_responses(
chklst_response_id,
checklist_item_id,
object_version_number,
arc_response_for_entity_code,
response_flag,
response_for_entity_id,
created_by,
creation_date,
last_updated_by,
last_update_date,
last_update_login
) VALUES (
DECODE( px_chklst_response_id, FND_API.G_MISS_NUM, NULL, px_chklst_response_id),
DECODE( p_checklist_item_id, FND_API.G_MISS_NUM, NULL, p_checklist_item_id),
DECODE( px_object_version_number, FND_API.G_MISS_NUM, 1, px_object_version_number),
DECODE( p_arc_response_for_entity_code, FND_API.g_miss_char, NULL, p_arc_response_for_entity_code),
DECODE( p_response_flag, FND_API.g_miss_char, NULL, p_response_flag),
DECODE( p_response_for_entity_id, FND_API.G_MISS_NUM, NULL, p_response_for_entity_id),
DECODE( p_created_by, FND_API.G_MISS_NUM, FND_GLOBAL.USER_ID, p_created_by),
DECODE( p_creation_date, FND_API.G_MISS_DATE, SYSDATE, p_creation_date),
DECODE( p_last_updated_by, FND_API.G_MISS_NUM, FND_GLOBAL.USER_ID, p_last_updated_by),
DECODE( p_last_update_date, FND_API.G_MISS_DATE, SYSDATE, p_last_update_date),
DECODE( p_last_update_login, FND_API.G_MISS_NUM, FND_GLOBAL.CONC_LOGIN_ID, p_last_update_login));
END Insert_Row;
PROCEDURE Update_Row(
p_chklst_response_id NUMBER,
p_checklist_item_id NUMBER,
p_object_version_number IN NUMBER,
p_arc_response_for_entity_code VARCHAR2,
p_response_flag VARCHAR2,
p_response_for_entity_id NUMBER,
p_last_updated_by NUMBER,
p_last_update_date DATE,
p_last_update_login NUMBER)
IS
BEGIN
Update pv_ge_chklst_responses
SET
chklst_response_id = DECODE( p_chklst_response_id, null, chklst_response_id, FND_API.G_MISS_NUM, null, p_chklst_response_id),
checklist_item_id = DECODE( p_checklist_item_id, null, checklist_item_id, FND_API.G_MISS_NUM, null, p_checklist_item_id),
object_version_number = nvl(p_object_version_number,0) + 1 ,
arc_response_for_entity_code = DECODE( p_arc_response_for_entity_code, null, arc_response_for_entity_code, FND_API.g_miss_char, null, p_arc_response_for_entity_code),
response_flag = DECODE( p_response_flag, null, response_flag, FND_API.g_miss_char, null, p_response_flag),
response_for_entity_id = DECODE( p_response_for_entity_id, null, response_for_entity_id, FND_API.G_MISS_NUM, null, p_response_for_entity_id),
last_updated_by = DECODE( p_last_updated_by, null, last_updated_by, FND_API.G_MISS_NUM, null, p_last_updated_by),
last_update_date = DECODE( p_last_update_date, null, last_update_date, FND_API.G_MISS_DATE, null, p_last_update_date),
last_update_login = DECODE( p_last_update_login, null, last_update_login, FND_API.G_MISS_NUM, null, p_last_update_login)
WHERE chklst_response_id = p_chklst_response_id
AND object_version_number = p_object_version_number;
END Update_Row;
PROCEDURE Delete_Row(
p_chklst_response_id NUMBER,
p_object_version_number NUMBER)
IS
BEGIN
DELETE FROM pv_ge_chklst_responses
WHERE chklst_response_id = p_chklst_response_id
AND object_version_number = p_object_version_number;
END Delete_Row ;
SELECT *
FROM pv_ge_chklst_responses
WHERE chklst_response_id = p_chklst_response_id
AND object_version_number = p_object_version_number
FOR UPDATE OF chklst_response_id NOWAIT;