1 |
SELECT. bill_class AS pol_code, B. bill_name AS pol_name,. bill_no AS card_no, 'website' AS buy_path,. rev_clerk_code AS agent_code,. rev_clerk_type AS agent_type, to_char (. regist_date, 'yyyy-mm-dd') AS recip_date, to_char (. chk_date, 'yyyy-mm-dd') AS pay_date, to_char (. invalid_date, 'yyyy-mm-dd') AS invalid_date, case when chk_stat = '0' then' is not written off 'when chk_stat = '1' AND autochkflag = '1' then' has been automatically written off 'when chk_stat = '1' AND autochkflag =' 0 'then' has been manually written off 'when chk_stat = '2' then' lost 'when chk_stat = '3' then' voided 'when chk_stat = '4' then' 'WHEN chk_stat = '5' then' has been destroyed. 'When chk_stat = 'A' then' to be written off 'end AS recip_stat, rev_branch_no, B. bill_literal_price AS prem FROM shcvms. bill_grant_check a, shcvms. bill_class B WHERE. regist_date is not null and. bill_class = B. bill_class AND. bill_class IN ('123', '123', '123', '123', '123', '123', '123', '123', '123', '123 ', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123 ', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123 ', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123 ', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123 ', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123 ', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123 ', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123', '123 ', '123', '123', '123', '123', '123', '123', '123 ') |