【发布时间】:2020-03-08 04:22:23
【问题描述】:
我在以下数据透视块的查询中得到无效标识符,请帮助解决这个问题
select cif_id,
to_char(tran_date,'MON-YYYY'),
part_tran_type ,
tran_amt
from CUSTOM.HTD_OCT_DEC19 H,
tbaadm.gam
pivot
(count(1),
sum(tran_amt)
for **part_tran_type** in ('D','C'))
where h.tran_date ='24-DEC-2019'
and h.PSTD_FLG='Y'
and h.DEL_FLG='N'
and gam.cust_id='D46478329'
and h.cust_id=gam.cust_id
and rpt_code in ('20211','20212','20270','20271','20410','20420','20440',
'20501','20502','20504','60202');
【问题讨论】:
-
请格式化代码。请阅读“如何提问部分”。非常感谢