formula - Merge two general formatted cells in Excel (one holding a date, the other a time) but keep their respective formats -
I have an Excel spreadsheet that I need to import into SQL Server databases in a specific format. Data in the sheet is required, but in incompatible format for the datetime field in Excel.
I currently have the following cells formatted as 'normal':
DATE | TIME | DATETIME ----------------------------------- 2014-08-01 | 23:45 |
I want to add a DATETIME value of '2014-08-01 23: 45: 00.000' to DATE and TIME '
I have the following (If DATE was G2):
= TEXT (G2, "yyyy-mm-dd") & amp; "" & Amp; Text (H2, [What should I be kept here?])
But as you see, I can not do the work that the final formula What has been put in the part as I want
Any help would be greatly appreciated.
Thank you.
If you do this then it should work as expected:
= TEXT (G2, "yyyy-mm-dd") & amp; "" & Amp; Text (H2, "hh: The difference from the answer given by the page is that if you have second (also with millisecond accuracy) in your time, then grab it in the later version and format it correctly while the second number But "00.000" second second code (so you can lose any seconds). If your data is never in the case of seconds, then either is OK.
Comments
Post a Comment