How to convert timestampt into excel text - excel

I have a timestamp (1394475248) when I translates using =(((Column/60)/60)/24)+DATE(1970,1,1) and the date format gives the timestamp (YYYY-MM-DD hh:mm:ss ) but I have to store it in a timestamp which looks like this "2014-03-10T23:11:09.000+0100" as all the previous data was in this format and changing would require a great deal of work/time.
Can someone tell what is the timestamp format and how do i convert the number to the exact format? many thanks
W

Try using TEXT function to convert to s strng in required format, e.g. with your original timestamp in A2 use this formula to convert and format
=TEXT(A2/86400+DATE(1970,1,1),"YYYY-MM-DDThh:mm:ss.000")&"+0100"

Related

In MS Excel, how can you convert mm.ss into mm:ss?

Is there a way to convert a time in the format mm.ss into mm:ss?
For example, I have an entire column going down:
12.37,
1.34,
5.36
I want it to say:
00:12:37,
00:01:34,
00:05:36
I've tried using the find/replace tool on Excel, but since the values are formatted as "number" rather than duration, changing them ends up changing it into some kind of larger value.
Is there a way to just replace . to : and turn my numbers into a duration format?
Thanks!
use:
=--("00:"&SUBSTITUTE(A1,".",":"))
Then format the output as hh:mm:ss

Acumatica Report Writer extract date from date time field

In Acumatica advanced report writer i have a date parameter but when i print this it shows in DD/MM/YYYY HH:MM:SS format. What is the format syntax so it only shows the date in DD/MM/YYYY format?
Thanks
Use the report designer format field:
Date format syntax is from .Net Framework:
custom date and time format strings
If you need a hardcoded format (with slashes) use 'dd/MM/yyyy'.
If you only want the short date format (date without time) use 'd'.
I would pick 'd' format if all you want is to remove time because it will follow the culture and still provide a short date.
Example: 'MM-dd-yyyy' or 'dd/MM/yyyy' etc...

Excel custom time format with optional hours

I have a range of data which are in a time format of hh:mm.ss (my original dataset is imported through a csv this way). I need to transform it to a correct format (hh:mm:ss) to make calculations and that's easily done using the replace functionality.
The issue is that some of these data don't have the hh part, they are just mm.ss, so when I replace "." with ":" they become hh:mm instead of mm:ss, e.g. 06m.30s becomes 06h:30m.
Does anyone know how to make a custom time format that will take as default value the mm and include the hh only when necessary?
This assumes that during the import process, the time column is imported as TEXT
EDIT: Formula shortened.
Convert the values to a REAL Excel time
=TIMEVALUE(SUBSTITUTE(IF(ISERR(FIND(":",A2)),"00:"&A2,A2),".",":"))
or
=--(SUBSTITUTE(IF(ISERR(FIND(":",A2)),"00:"&A2,A2),".",":"))
Apply your desired Time format to the result
hh:mm:ss

Excel 2010 Convert text string to Full date & 24 hr time

Program: Excel 2010
Issue: External report gives me a text string, I want to convert it to Date & 24 hour time.
141221205535 needs to be:
14/12/21 20:55:35
I have tried text to columns making the result show: YMD
I have then tried using the format cells option: (custom) yy/mm/dd hh:mm:ss
* I receive a string of ######## in the Sample field in the formatting box.
I have tried also just using the date/time version, no seconds
1412212055 needs to be:
14/12/21 20:55
ideally, if possible:
20141421 2055 or 2014/14/21 20:55 I will accept
I can not alter the report as it comes through a 3rd party and I am pulling the date from a 'reference' field. The report, when downloaded, is in CSV and there is no existing formatting on the data.
I need to convert this as my sales report then needs to be sorted by date order.
Note: If I do use the seconds in the string, I get the weird looking scientific number. So i've had to reduce the digits, this isn't ideal, is there a way to avoid the scientific number whilst the process of changing 'text to date' is happening?
Thanks in advance.
I used this formula to convert:
=TEXT(A1,"2000-00-00 00\:00\:00")+0
format result cell in required format, e.g. yyyy/mm/dd hh:mm:ss
If you don't want the seconds in the underlying value you can use this version
=TEXT(LEFT(A1,10),"2000-00-00 00\:00")+0
These formulas work because TEXT function converts your value 141221205535 to a text value 2014-12-21 20:55:35, then, because that is a valid date/time format in Excel the +0 "co-erces" the text value to a serial number representing the correct date/time in Excel.....so you can then simply format the result to display any way you want.
Note that I'm assuming all dates will be in the current (21st) century.....
A formula like this would work -
=TEXT(DATE(LEFT(A1,2),MID(A1,3,2),MID(A1,5,2))+TIME(MID(A1,7,2),MID(A1,9,2),MID(A1,11,2)),"yy/mm/dd hh:mm:ss")
If your format always has 12 digits
You'll need to add the datevalue with the timevalue to get also the HMS
for example (suppose the text is in D5 cell):
=DATEVALUE(LEFT(D5,2)&"-"&MID(D5,3,2)&-MID(D5,5,2))+TIMEVALUE(MID(D5,7,2)&":"&MID(D5,9,2)&":"&RIGHT(D5,2))`

Date format YYYY-MM-DD+11:00 convert in to YYY-MM-DD HH:MM:SS

I Received excel data with following format
Date format YYYY-MM-DD+11:00 (Ex 2014-02-15+11:00 /2014-02-18+13:00)
Now I need to convert into this format
2014-02-18 HH:MM:SI
Please help me to do this
cheers
Just did a quick test. It's a little sloppy, but this formula will work. For the sake of argument, it assumes that the data you're trying to convert is in A1 of the current sheet, that it's all the same length, and that the format is "General":
=SUM(DATEVALUE(LEFT(A1,10)),TIMEVALUE(RIGHT(A1,5)))
Wherever you use the above formula, change the format to the Custom Format YYYY-MM-DD HH:MM:SI. I'm not sure what you're looking for with SI. I'm taking that literally. That custom format will display the seconds value and then the letter I. If you're looking for a different value, like milliseconds, then you can look that up. But if the data you're converting is in a "General" format, when you convert it, it won't have seconds or milliseconds, anyway. Those will all get converted to 00s.

Resources