The following lines contain the word 'select', 'insert', 'update' or 'delete':
select null
from ame_item_class_usages
where application_id = p_application_id and item_class_id =
( select item_class_id from ame_attributes
where attribute_id = p_attribute_id and sysdate between start_date
and nvl(end_date - ame_util.oneSecond,sysdate))
and sysdate between start_date and nvl(end_date - ame_util.oneSecond,sysdate);
select approver_type_id
into l_approver_type_id
from ame_attributes
where attribute_id = p_attribute_id and
sysdate between start_date and
nvl(end_date - ame_util.oneSecond, sysdate) ;
select variable_value
into l_variable_Value
from ame_config_vars
where
variable_name = 'allowAllApproverTypes' and
application_id = p_application_id and
sysdate between start_date and
nvl(end_date - ame_util.oneSecond, sysdate);
select variable_value
into l_variable_Value
from ame_config_vars
where
variable_name = 'allowAllApproverTypes' and
application_id = 0 and
sysdate between start_date and
nvl(end_date - ame_util.oneSecond, sysdate) ;
select orig_system into l_orig_system from ame_approver_types
where approver_type_id = l_approver_type_id and
sysdate between start_date and
nvl(end_date - ame_util.oneSecond, sysdate) ;
select count(*) into l_count
from fnd_flex_value_sets
where flex_value_set_id = p_value_set_id and
instr(flex_value_set_name,'$') = 0 ;
select attribute_type
into l_attribute_type
from ame_attributes
where attribute_id = p_attribute_id
and sysdate between start_date and
nvl(end_date - ame_util.oneSecond, sysdate) ;
select format_type into l_format_type
from fnd_flex_value_sets
where flex_value_set_id = p_value_set_id and
instr(flex_value_set_name,'$') = 0 ;
select null
from ame_attributes
where
attribute_id = p_attribute_id and
p_effective_date between start_date and
nvl(end_date - ame_util.oneSecond, p_effective_date) ;
select null
from ame_calling_apps
where
application_id = p_application_id and
p_effective_date between start_date and
nvl(end_date - ame_util.oneSecond, p_effective_date) ;
select count(*)
from ame_attribute_usages
where
attribute_id = p_attribute_id and
application_id = p_application_id and
p_effective_date between start_date and
nvl(end_date - ame_util.oneSecond, p_effective_date) ;
select name,attribute_type
into l_attribute_name,l_attribute_type
from ame_attributes
where attribute_id = p_attribute_id
and p_effective_date between start_date and
nvl(end_date - ame_util.oneSecond, p_effective_date) ;
select name
into l_attr_name
from ame_attributes
where attribute_id = p_attribute_id
and sysdate between start_date and nvl(end_date - (1/86400),sysdate);
select ame_util2.specialObject
into l_object
from ame_attributes
where attribute_id = p_attribute_id
and name in (ame_util.jobLevelStartingPointAttribute
,ame_util.nonDefStartingPointPosAttr
,ame_util.nonDefPosStructureAttr
,ame_util.supStartingPointAttribute
,ame_util.firstStartingPointAttribute
,ame_util.secondStartingPointAttribute
)
and sysdate between start_date and nvl(end_date - (1/86400), sysdate);
Procedure chk_non_updateable_args
(p_effective_date in date
,p_rec in ame_atu_shd.g_rec_type
) IS
--
l_proc varchar2(72) := g_package || 'chk_non_updateable_args';
fnd_message.set_name('PER', 'AME_400467_NON_UPDATEABLE_FIELD');
fnd_message.set_name('PER', 'AME_400467_NON_UPDATEABLE_FIELD');
fnd_message.set_name('PER', 'AME_400467_NON_UPDATEABLE_FIELD');
End chk_non_updateable_args;
procedure chk_delete
(p_attribute_id in number,
p_application_id in integer,
p_object_version_number in number,
p_effective_date in date) is
l_proc varchar2(72) := g_package||'chk_delete';
select use_count
from ame_attribute_usages
where
attribute_id = p_attribute_id and
application_id = p_application_id and
sysdate between start_date and
nvl(end_date-(ame_util.oneSecond),sysdate);
select null
from ame_mandatory_attributes
where
attribute_id = p_attribute_id and
action_type_id = -1 and
p_effective_date between start_date and
nvl(end_date - ame_util.oneSecond, p_effective_date) ;
end chk_delete;
Procedure dt_update_validate
(p_attribute_id in number default hr_api.g_number
,p_datetrack_mode in varchar2
,p_validation_start_date in date
,p_validation_end_date in date
) Is
--
l_proc varchar2(72) := g_package||'dt_update_validate';
End dt_update_validate;
Procedure dt_delete_validate
(p_attribute_id in number
,p_application_id in number
,p_datetrack_mode in varchar2
,p_validation_start_date in date
,p_validation_end_date in date
) Is
--
l_proc varchar2(72) := g_package||'dt_delete_validate';
If (p_datetrack_mode = hr_api.g_delete or
p_datetrack_mode = hr_api.g_zap) then
--
--
-- Ensure the arguments are not null
--
hr_api.mandatory_arg_error
(p_api_name => l_proc
,p_argument => 'validation_start_date'
,p_argument_value => p_validation_start_date
);
End dt_delete_validate;
Procedure insert_validate
(p_rec in ame_atu_shd.g_rec_type
,p_effective_date in date
,p_datetrack_mode in varchar2
,p_validation_start_date in date
,p_validation_end_date in date
) is
--
l_proc varchar2(72) := g_package||'insert_validate';
End insert_validate;
Procedure update_validate
(p_rec in ame_atu_shd.g_rec_type
,p_effective_date in date
,p_datetrack_mode in varchar2
,p_validation_start_date in date
,p_validation_end_date in date
) is
--
l_proc varchar2(72) := g_package||'update_validate';
dt_update_validate
(p_attribute_id => p_rec.attribute_id
,p_datetrack_mode => p_datetrack_mode
,p_validation_start_date => p_validation_start_date
,p_validation_end_date => p_validation_end_date
);
chk_non_updateable_args
(p_effective_date => p_effective_date
,p_rec => p_rec
);
End update_validate;
Procedure delete_validate
(p_rec in ame_atu_shd.g_rec_type
,p_effective_date in date
,p_datetrack_mode in varchar2
,p_validation_start_date in date
,p_validation_end_date in date
) is
--
l_proc varchar2(72) := g_package||'delete_validate';
dt_delete_validate
(p_datetrack_mode => p_datetrack_mode
,p_validation_start_date => p_validation_start_date
,p_validation_end_date => p_validation_end_date
,p_attribute_id => p_rec.attribute_id
,p_application_id => p_rec.application_id
);
chk_delete
(p_attribute_id => p_rec.attribute_id,
p_application_id => p_rec.application_id,
p_object_version_number => p_rec.object_version_number,
p_effective_date => p_effective_date);
End delete_validate;