Reg Person type in oralce forms
609109Aug 10 2009 — edited Aug 10 2009There are 2 blocks namely BLOCKNAME,COC_HR_EMPLOYEE_V. BLOCKNAME is a query block.PERSON_TYPE is part of query block and it is combo box. It contains 'Employees Only' ,'consultants only' and 'Both'.
When I select 'consultants only' , it is not retrieving 'consultants only' records. It is rertieving all records that includes employees and consultans. Here is my code.
IF :BLOCKNAME.PERSON_TYPE IS NOT NULL THEN
IF :BLOCKNAME.PERSON_TYPE='Employees Only' THEN
SET_BLOCK_PROPERTY('COC_HR_EMPLOYEE_V', ONETIME_WHERE, 'SYSTEM_PERSON_TYPE IN (''EMP'', ''EMP_APL'')');
END IF;
IF :BLOCKNAME.PERSON_TYPE='consultants Only' THEN
SET_BLOCK_PROPERTY('COC_HR_EMPLOYEE_V', ONETIME_WHERE, 'SYSTEM_PERSON_TYPE IN (''OTHER'', ''CWK'')');
END IF;
IF :BLOCKNAME.PERSON_TYPE='Both' THEN
SET_BLOCK_PROPERTY('COC_HR_EMPLOYEE_V', ONETIME_WHERE, 'SYSTEM_PERSON_TYPE IN (''EMP'', ''EMP_APL'',''CWK'',''OTHER'')');
END IF;
END IF;
Basically, code is not working. it is not going in the if condition.
Please advise me. Thanks in advance