I get the date and time from the database as follows
Date: 20100101 (YYYY / MM / DD) Time: 120912 (HH: MM: SS)
I need to format the date as follows: 20100101 → (2010-10-11) (see to have) "-" between year and month and day
I need to format the time as follows: 120912 → 12:02:12 Suppose I can have time as 62367 from the database
06:23:67
source
share