By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
with t1 ( c1, c2 )
as
( select 'JANUAR' c1, 'MAI' c2 from dual union all
select 'JANUAR' c1, 'FEBRUAR' c2 from dual
)
select to_date(c1,'MONTH', 'NLS_DATE_LANGUAGE=German' ) as c1 ,
to_date(c2, 'MONTH', 'NLS_DATE_LANGUAGE=German' ) as c2,
sysdate-180 as date_calculation
from t1
where sysdate-180 between to_date(c1,'MONTH', 'NLS_DATE_LANGUAGE=German' )
and to_date(c2, 'MONTH', 'NLS_DATE_LANGUAGE=German' )
;
C1 | C2 | DATE_CALCULATION |
---|---|---|
01-JAN-21 | 01-MAY-21 | 25-MAR-21 |