java logic for date time handling as per output file
Hi,
I am developing map using cMap and route in Talend .
I need the java code for splitting the date in hourly basis in output file. The dates can be from any date to any date, it can be a day or more, but we need to split it in hour basis.
So, If input is 2020-02-24T09:00:00;2020-02-24T11:00:00 - It should make 9 to 10 in 1st line and 10 to 11 in second line of output. Sample files are given below -
The output file is like below - M1;45;2020-02-24T09:00:00;2020-02-24T10:00:00;;;W M1;46;2020-02-24T10:00:00;2020-02-24T11:00:00;;;W M1;47;2020-02-24T11:00:00;2020-02-24T12:00:00;;;W M1;48;2020-02-24T12:00:00;2020-02-24T13:00:00;;;W