|
database
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
any idea how to decode hex time string '0x01 C6 56 B1 8C EA 40 00'Hi there,
I'm trying to understand a database for which information is not available concerning how it writes time values. Here is an example: Start time: 0x01 C6 56 B1 8C EA 40 00 End time: 0x01 C6 57 7A B7 53 FF FF I assume it contains date as well, any ideas of how I should go about this? chentiangemalc wrote:
> I'm trying to understand a database for which information is not available chentiangemalc,> concerning how it writes time values. > > Here is an example: > > Start time: 0x01 C6 56 B1 8C EA 40 00 > End time: 0x01 C6 57 7A B7 53 FF FF > > I assume it contains date as well, any ideas of how I should go about this? Do you know the difference in time between start time and end time? Also can you enter a date of your choosing into this 'database' and see this result? Does this help: PRINT 'Start time:' SELECT CHAR(0x01) + CHAR(0xC6) + CHAR(0x56) + CHAR(0xB1) + CHAR(0x8C) + CHAR(0xEA) + CHAR(0x40) + CHAR(0x00) SELECT CAST(0x01 AS int), CAST(0xC6 AS int), CAST(0x56 AS int), CAST(0xB1 AS int), CAST(0x8C AS int), CAST(0xEA AS int), CAST(0x40 AS int), CAST(0x00 AS int) PRINT 'End time:' SELECT CHAR(0x01) + CHAR(0xC6) + CHAR(0x57) + CHAR(0x7A) + CHAR(0xB7) + CHAR(0x53) + CHAR(0xFF) + CHAR(0xFF) SELECT CAST(0x01 AS int), CAST(0xC6 AS int), CAST(0x57 AS int), CAST(0x7A AS int), CAST(0xB7 AS int), CAST(0x53 AS int), CAST(0xFF AS int), CAST(0xFF AS int) -Tav.- Tavis Pitt It seems to be the number of nanoseconds that have lapsed since 1/1/1970
0:00... Show quote "Tav" wrote: > > chentiangemalc wrote: > > I'm trying to understand a database for which information is not available > > concerning how it writes time values. > > > > Here is an example: > > > > Start time: 0x01 C6 56 B1 8C EA 40 00 > > End time: 0x01 C6 57 7A B7 53 FF FF > > > > I assume it contains date as well, any ideas of how I should go about this? > > chentiangemalc, > > Do you know the difference in time between start time and end time? > Also can you enter a date of your choosing into this 'database' and see > this result? > > Does this help: > > PRINT 'Start time:' > SELECT CHAR(0x01) + CHAR(0xC6) + CHAR(0x56) + CHAR(0xB1) + CHAR(0x8C) + > CHAR(0xEA) + CHAR(0x40) + CHAR(0x00) > SELECT CAST(0x01 AS int), CAST(0xC6 AS int), CAST(0x56 AS int), > CAST(0xB1 AS int), CAST(0x8C AS int), CAST(0xEA AS int), CAST(0x40 AS > int), CAST(0x00 AS int) > > PRINT 'End time:' > SELECT CHAR(0x01) + CHAR(0xC6) + CHAR(0x57) + CHAR(0x7A) + CHAR(0xB7) + > CHAR(0x53) + CHAR(0xFF) + CHAR(0xFF) > SELECT CAST(0x01 AS int), CAST(0xC6 AS int), CAST(0x57 AS int), > CAST(0x7A AS int), CAST(0xB7 AS int), CAST(0x53 AS int), CAST(0xFF AS > int), CAST(0xFF AS int) > > -Tav.- > > Tavis Pitt > > Oh I have figured out it's Windows 64 bit big endian time...
So 0x01 C6 56 B1 8C EA 40 00 = Mon, 03 April 2006 00:00:00 UTC 0x01 C6 57 7A B7 53 FF FF = Tue, 04 April 2006 00:00:00 UTC However I still haven't found much good info on this time format... I found this out using a decoder program found at http://www.digital-detective.co.uk/freetools/decode.asp However to decode myself not sure yet... Show quote "chentiangemalc" wrote: > Hi there, > > I'm trying to understand a database for which information is not available > concerning how it writes time values. > > Here is an example: > > Start time: 0x01 C6 56 B1 8C EA 40 00 > End time: 0x01 C6 57 7A B7 53 FF FF > > I assume it contains date as well, any ideas of how I should go about this? > |
|||||||||||||||||||||||