Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2003
    Posts
    8

    Unanswered: Convert a date into timestamp

    Im need to convert a date e.g '10/12/2002' into a timestamp so I can use it to query a Sybase DB

  2. #2
    Join Date
    May 2003
    Posts
    23
    What I would do is to convert the date into ISO format, then insert the value into the database.

    Using VBScript:
    Code:
    Function ConvertISODate(dteDate)
    	dteYear = Year(dteDate)
    	dteMonth = Month(dteDate)
    	dteDay = Day(dteDate)
    	ConvertISODate = dteYear & Right(CStr(dteMonth)+100,2) & Right(CStr(dteDay)+100,2)
    End Function

Posting Permissions

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