How to split date, time and convert to 12h time format

Note: Please read the article carefully before proceeding! If in the process of using …