Results 1 to 11 of 11
  1. #1
    Join Date
    Apr 2004
    Location
    Miami, FL
    Posts
    9

    Unhappy Unanswered: Problem converting UTC dates in dts

    Can anyone help me convert UTC dates in a dts package? I have a db I need to transform, but all the dates are in utc format. Is there a function I can use in an ActiveX transformation script to convert, say, 38166, to a valid datetime value? There seems to be almost no documentation in using utc in SQL.

  2. #2
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    How is that a UTC time?

    http://www.dxing.com/utcgmt.htm
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  3. #3
    Join Date
    Jul 2004
    Posts
    60
    I'll try...but for the record i dont think 38166 is a valid UTC date.
    Please correct me if i'm wrong.

    here is what i thougght UTC date looked like:

    2004-07-01T16:15:30

    SQL server CAST and CONVERT will handle this for you, by default.

  4. #4
    Join Date
    Jul 2004
    Posts
    60
    But your example does somewhat resemble a Julian date....

  5. #5
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    Quote Originally Posted by oddity
    But your example does somewhat resemble a Julian date....
    1938?

    or 2038?

    But yeah it looks more julian..
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  6. #6
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    My vote is for 2008, since the Unix epoch is based on 1970.

    -PatP

  7. #7
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    I'll go with thta...(since I wrote a udf for that one once)....god damn toolbox...got to clean this damn thing out....

    Wait a minute....
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  8. #8
    Join Date
    Jul 2004
    Posts
    60
    i bet there'll be a party or 2 ~3:15 on Jan 19 2038

    the end of the world as we know it.


  9. #9
    Join Date
    Jul 2004
    Posts
    60
    you've got a julian date converting UDF?

    Oooooo...i've wanted to do that but never had a project that required it.

    Care to share????

  10. #10
    Join Date
    Feb 2004
    Location
    In front of the computer
    Posts
    15,579
    Provided Answers: 54
    I wrote one ages ago for military style Julian dates, and just posted it a day or two ago. Check here for details.

    -PatP

  11. #11
    Join Date
    Jul 2004
    Posts
    60
    thanks much.

    sorry for the thread hijack chunky,
    did you get a decent answer for the original post?

    perhaps you could post an example of the date string you are dealing with, if not?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •