반응형
예시1
select case 필드명
when @abap_true Then 'Y'
when @space Then 'X'
END AS 필드명
from DBtable
예시2: 수정자 우선발췌
case aenam
when @space then ernam
else aenam
end as ernam
join시 null값 발생할 수 있음.
그리므로 coalesce를 써야함
예시3
case coalesce(aenam, @space)
when @space then ernam
else aenam
end as ernam
예시4
case coalsece(erdat, '00000000')
이하 같음
반응형
'SAP > ABAP New Syntax' 카테고리의 다른 글
ABAP corresponding 신문법 (1) | 2021.11.26 |
---|---|
ABAP new syntax line_exists (0) | 2021.11.12 |
ABAP New syntax - filter (0) | 2020.11.15 |
ABAP New syntax - switch, cond (0) | 2020.11.08 |
ABAP New Syntax - Value (3) | 2020.03.25 |