I'm attempting to use SASDOS in my statement below, but it's failing to be found. My understanding is that I have to use a form of derived table to access this new column. Is this correct? If so, could someone please help elaborate on how to do that?
proc sql;
create table TEST as
select
DQBBDA AS 'Sbm Date'n,
case when 'Sbm Date'n > 999999
then input('1' || substr(put('Sbm Date'n,z8.),3), z7.)
end as SASDOS format=z7.
from
DB2SCHEMA.ORIGIN
where
SASDOS = 1130314;
quit;