Hello,
I need to create a table in sql server in which
In the first column , the first row should to have a data from inception till jan end date, and second row should have data from inception till feb end dateand
third row should have data from inception till march end date. .
In the second column, first row needs to have a data of only jan date, and second row should have data of only feb date and
third row should have data of only march date.
Preetham ThangammaPosted May 9, 2023, 10:07 AM
Hi Naimish Makwana
My requirement is to retrieve the data first using the where condition and then insert it into another table.So, i need the guidance to write the where clause for the above mentioned requirement
Thank you
Naimish MakwanaPosted May 8, 2023, 12:20 PM
Try below
You'll need to replace
,,,,,, andwith the actual dates you need to use in your table.For example, if your inception date is January 1st, 2021 and your January end date is January 31st, 2021, you would replace
with'2021-01-01'andwith'2021-01-31'. Similarly, replaceandwith the February and March end dates, respectively, and,, andwith the January, February, and March dates, respectively.Thanks