HI all,
I have a table test1 having column review_Period(varchar2 30)
Data in table
H1 2020
Q2 2020
Q1 2020
H2 2019
Q3 2019
Q4 2020
FY 2019
Now based on values from above table I hav to insert value in another table test2
H1-->half yearly first half(1st jan-31st june) for respective year
H2-->Second half(1st july-31st Dec)
Q1/Q2/Q3/Q4--4 quarters
Q1--ist jan-31st march
Q2--1st April--30th June
Q3--1st july--30th September
Q4-1st October--31st December
FY-->stands for annually
Now I have to insert data into two columns of other table
test2 having columns(PERIOD_START_DATE,PERIOD_END_DATE) BASED ON Q1/Q2/Q3/Q4/H1/H2/FY ,Please help me with logic.
For ex for H2 : Period_start_date will be :07/01/2020(If year is 2020),Period_end_date:12/31/2020
Q3: Period_start_date will be: 07/01/2020,Period_end_date will be 09/30/2020