我正在尝试为已经派生的列“Sub1”设置默认文本值这可能吗?我已经为要使用 0 值派生的列创建了占位符。如果重要的话,我正在 Teradata 工作.....谢谢!
select c_clm
,dt.Claimant_Name
,dt.i_ssn
,0 as "Time_Period"
,0 as "Unit_ID",
/*,idv.C_PDT AS "Product"
,er.C_FRM_POL AS "Group Product",*/
(case
when idv.c_pdt is null then 'GLTC'
else idv.c_pdt
end) as "Product_ID"
,c_ams_clm as "DBS_UserID"
,upc_indiv_org_id as "DBS_EEID"
,0 as "Categ"
,0 as Categ_sort
,0 as "Sub1"
,0 as "Sub1_Sort"
,0 as "Sub2"
,0 as "Sub2_Sort"
,0 as "MTD_Num"
,0 as "MTD_Denom"
,dt.i_pol as "Policy_Number"
,COALESCE (erpol.n_pol,idv.n_pol, ks.n_pol)