Results 1 to 3 of 3

Thread: DATETIME Issue

  1. #1
    Join Date
    Mar 2006
    Posts
    82

    Unanswered: DATETIME Issue

    Hi all

    I am having a problem with how the DATE field of a column is being displayed. What I am trying to do is run a DTS that takes the info from a table and places it into a flat file. Of course the format of the flat file does not need the trailing 23:59:59.993. When running a view it gives us the proper format of mm/dd/yyyy but the rest is not being shown in the view. A Cast function in the view into a VARCHAR changes it to something like Oct, 10, 2006. And of course the LEFT function comes up with the same Oct, 10, 2006 format.

    How would I tell SQL server to just grab just 10/06/2006 and nothing else or without it trying to change it to a different format?

    Thanks

  2. #2
    Join Date
    Jan 2003
    Location
    Massachusetts
    Posts
    5,800
    Provided Answers: 11
    Look up the Convert function in BOL. There are a number of formats to display a date in.

  3. #3
    Join Date
    Mar 2006
    Posts
    82
    Wonderful, thanks!

Posting Permissions

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