Commit 8816020a authored by caluka's avatar caluka

sql updated to add Analysis Class yearly in Physical Count Scheduler[D14DSUN016].


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@95685 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 1c08ebb2
ALTER TABLE SITEITEM ADD ANALYSIS_CLASS CHAR(1);
ALTER TABLE SITEITEM ADD CYCLE_CRITERIA CHAR(1);
create or replace function get_analysis_class(as_site_code char, as_item_code char)
return char is as_anal_class char ;
begin
begin
select analysis_class into as_anal_class
from siteitem
where site_code = as_site_code
and item_code = as_item_code;
if trim(as_anal_class) is null then
select analysis_class into as_anal_class
from item
where item_code = as_item_code;
return as_anal_class;
else
return as_anal_class;
end if;
exception
when no_data_found then
select analysis_class into as_anal_class
from item
where item_code = as_item_code;
return as_anal_class;
end;
return as_anal_class;
end;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment