答案 0 :(得分:0)
你可以尝试这个查询,它会起作用
select max(classid),
classname,
max(frequency),
max(notice),
max(typeofdays),
max(rnotice),
max(classpercent)
from <table_name>
group by classname;
答案 1 :(得分:0)
使用滞后和分区可以解决我的要求
SELECT FUND_CLASS_ID,
NVL(SUB_NOTICE_DAYS , LAG (SUB_NOTICE_DAYS , 1) OVER (PARTITION BY LFC.ID ORDER BY SUB_NOTICE_DAYS NULLS LAST)) SUB_NOTICE_DAYS ,
NVL(SUB_NOTICE_TYPE_OF_DAYS_ID , LAG (SUB_NOTICE_TYPE_OF_DAYS_ID , 1) OVER (PARTITION BY LFC.ID ORDER BY SUB_NOTICE_TYPE_OF_DAYS_ID NULLS LAST)) SUB_NOTICE_TYPE_OF_DAYS_ID
FROM CLASS