The following lines contain the word 'select', 'insert', 'update' or 'delete':
PROCEDURE insert_row
(
p_api_version IN NUMBER
,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
,p_commit IN VARCHAR2 := fnd_api.g_false
,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
,p_object_type IN NUMBER
,p_object_id IN NUMBER
,p_organization_id IN NUMBER
,p_owning_department_id IN NUMBER := NULL
,p_accounting_class_code IN VARCHAR2 := NULL
,p_area_id IN NUMBER := NULL
,p_activity_cause_code IN VARCHAR2 := NULL
,p_activity_type_code IN VARCHAR2 := NULL
,p_activity_source_code IN VARCHAR2 := NULL
,p_work_order_type IN NUMBER := NULL
,p_planner IN NUMBER := NULL
,p_firm IN NUMBER := NULL
,p_planned IN VARCHAR2 := NULL
,p_notification_required IN VARCHAR2 := NULL
,p_shutdown_type_code IN VARCHAR2 := NULL
,p_tagging_required_flag IN VARCHAR2 := NULL
,x_return_status OUT NOCOPY VARCHAR2
,x_msg_count OUT NOCOPY NUMBER
,x_msg_data OUT NOCOPY VARCHAR2
) IS
l_api_name CONSTANT VARCHAR2(30) := 'insert_row';
INSERT INTO eam_org_maint_defaults
(
object_type
,object_id
,organization_id
,owning_department_id
,accounting_class_code
,area_id
,activity_cause_code
,activity_type_code
,activity_source_code
,work_order_type
,planner_maintenance
,firm_planned_flag
,plan_maintenance
,notification_required
,shutdown_type_code
,tagging_required_flag
,created_by
,creation_date
,last_updated_by
,last_update_date
,last_update_login
)
VALUES
(
p_object_type
,p_object_id
,p_organization_id
,p_owning_department_id
,p_accounting_class_code
,p_area_id
,p_activity_cause_code
,p_activity_type_code
,p_activity_source_code
,p_work_order_type
,p_planner
,p_firm
,p_planned
,p_notification_required
,p_shutdown_type_code
,p_tagging_required_flag
,fnd_global.user_id
,sysdate
,fnd_global.user_id
,sysdate
,fnd_global.login_id
);
END insert_row;
PROCEDURE update_row
(
p_api_version IN NUMBER
,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
,p_commit IN VARCHAR2 := fnd_api.g_false
,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
,p_object_type IN NUMBER
,p_object_id IN NUMBER
,p_organization_id IN NUMBER
,p_owning_department_id IN NUMBER := NULL
,p_accounting_class_code IN VARCHAR2 := NULL
,p_area_id IN NUMBER := NULL
,p_activity_cause_code IN VARCHAR2 := NULL
,p_activity_type_code IN VARCHAR2 := NULL
,p_activity_source_code IN VARCHAR2 := NULL
,p_work_order_type IN NUMBER := NULL
,p_planner IN NUMBER := NULL
,p_firm IN NUMBER := NULL
,p_planned IN VARCHAR2 := NULL
,p_notification_required IN VARCHAR2 := NULL
,p_shutdown_type_code IN VARCHAR2 := NULL
,p_tagging_required_flag IN VARCHAR2 := NULL
,x_return_status OUT NOCOPY VARCHAR2
,x_msg_count OUT NOCOPY NUMBER
,x_msg_data OUT NOCOPY VARCHAR2
) IS
l_api_name CONSTANT VARCHAR2(30) := 'update_row';
UPDATE eam_org_maint_defaults SET
owning_department_id = decode(p_owning_department_id, fnd_api.g_miss_num, null, null, owning_department_id, p_owning_department_id)
,accounting_class_code = decode(p_accounting_class_code, fnd_api.g_miss_char, null, null, accounting_class_code, p_accounting_class_code)
,area_id = decode(p_area_id, fnd_api.g_miss_num, null, null, area_id, p_area_id)
,activity_cause_code = decode(p_activity_cause_code, fnd_api.g_miss_char, null, null, activity_cause_code, p_activity_cause_code)
,activity_type_code = decode(p_activity_type_code, fnd_api.g_miss_char, null, null, activity_type_code, p_activity_type_code)
,activity_source_code = decode(p_activity_source_code, fnd_api.g_miss_char, null, null, activity_source_code, p_activity_source_code)
,work_order_type = decode(p_work_order_type, fnd_api.g_miss_num, null, null, work_order_type, p_work_order_type)
,planner_maintenance = decode(p_planner, fnd_api.g_miss_num, NULL, NULL, planner_maintenance, p_planner)
,firm_planned_flag = decode(p_firm, fnd_api.g_miss_num, NULL, NULL, firm_planned_flag, p_firm)
,plan_maintenance = decode(p_planned, fnd_api.g_miss_char, NULL, NULL, plan_maintenance, p_planned)
,notification_required = decode(p_notification_required, fnd_api.g_miss_char, NULL, NULL, notification_required, p_notification_required)
,shutdown_type_code = decode(p_shutdown_type_code, fnd_api.g_miss_char, null, null, shutdown_type_code, p_shutdown_type_code)
,tagging_required_flag = decode(p_tagging_required_flag, fnd_api.g_miss_char, null, null, tagging_required_flag, p_tagging_required_flag)
,created_by = fnd_global.user_id
,creation_date = sysdate
,last_updated_by = fnd_global.user_id
,last_update_date = sysdate
,last_update_login = fnd_global.login_id
WHERE object_type = p_object_type AND object_id = p_object_id
AND organization_id = p_organization_id;
END update_row;
PROCEDURE update_insert_row
(
p_api_version IN NUMBER
,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
,p_commit IN VARCHAR2 := fnd_api.g_false
,p_validation_level IN NUMBER := fnd_api.g_valid_level_full
,p_object_type IN NUMBER
,p_object_id IN NUMBER
,p_organization_id IN NUMBER
,p_owning_department_id IN NUMBER := NULL
,p_accounting_class_code IN VARCHAR2 := NULL
,p_area_id IN NUMBER := NULL
,p_activity_cause_code IN VARCHAR2 := NULL
,p_activity_type_code IN VARCHAR2 := NULL
,p_activity_source_code IN VARCHAR2 := NULL
,p_work_order_type IN NUMBER := NULL
,p_planner IN NUMBER := NULL
,p_firm IN NUMBER := NULL
,p_planned IN VARCHAR2 := NULL
,p_notification_required IN VARCHAR2 := NULL
,p_shutdown_type_code IN VARCHAR2 := NULL
,p_tagging_required_flag IN VARCHAR2 := NULL
,x_return_status OUT NOCOPY VARCHAR2
,x_msg_count OUT NOCOPY NUMBER
,x_msg_data OUT NOCOPY VARCHAR2
) IS
l_api_name CONSTANT VARCHAR2(30) := 'update_insert_row';
SELECT count(*) INTO l_count
FROM eam_org_maint_defaults
WHERE object_type = p_object_type AND object_id = p_object_id
AND organization_id = p_organization_id;
insert_row
(
p_api_version => 1.0
,p_object_type => p_object_type
,p_object_id => p_object_id
,p_organization_id => p_organization_id
,p_owning_department_id => from_fnd_std_num(p_owning_department_id)
,p_accounting_class_code => from_fnd_std_char(p_accounting_class_code)
,p_area_id => from_fnd_std_num(p_area_id)
,p_activity_cause_code => from_fnd_std_char(p_activity_cause_code)
,p_activity_type_code => from_fnd_std_char(p_activity_type_code)
,p_activity_source_code => from_fnd_std_char(p_activity_source_code)
,p_work_order_type => from_fnd_std_num(p_work_order_type)
,p_planner => from_fnd_std_num(p_planner)
,p_firm => from_fnd_std_num(p_firm)
,p_planned => from_fnd_std_char(p_planned)
,p_notification_required => from_fnd_std_char(p_notification_required)
,p_shutdown_type_code => from_fnd_std_char(p_shutdown_type_code)
,p_tagging_required_flag => from_fnd_std_char(p_tagging_required_flag)
,x_return_status => x_return_status
,x_msg_count => x_msg_count
,x_msg_data => x_msg_data
);
update_row
(
p_api_version => 1.0
,p_object_type => p_object_type
,p_object_id => p_object_id
,p_organization_id => p_organization_id
,p_owning_department_id => p_owning_department_id
,p_accounting_class_code => p_accounting_class_code
,p_area_id => p_area_id
,p_activity_cause_code => p_activity_cause_code
,p_activity_type_code => p_activity_type_code
,p_activity_source_code => p_activity_source_code
,p_work_order_type => p_work_order_type
,p_planner => p_planner
,p_firm => p_firm
,p_planned => p_planned
,p_notification_required => p_notification_required
,p_shutdown_type_code => p_shutdown_type_code
,p_tagging_required_flag => p_tagging_required_flag
,x_return_status => x_return_status
,x_msg_count => x_msg_count
,x_msg_data => x_msg_data
);
END update_insert_row;