Results 1 to 3 of 3

Thread: datetime error

  1. #1
    Join Date
    Jan 2003
    Location
    India
    Posts
    523

    Question Unanswered: datetime error

    while executing the following statement:
    select convert(datetime,'Nov 31, 2002 10:05pm')
    got the following error:
    The conversion of a char data type to a datetime data type resulted in an out-of-range datetime value.

    the datetime set is mdy
    is there any way to make this work though this is not according to the iso standarts.

    regards,
    harsh.

  2. #2
    Join Date
    Jul 2003
    Location
    The Dark Planet
    Posts
    1,401
    Does november contain 31 days ... hmm .. something is very wrong with your code
    this works :-
    select convert(datetime,'Nov 30, 2002 10:41PM',107)
    Get yourself a copy of the The Holy Book

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

  3. #3
    Join Date
    Jan 2003
    Location
    India
    Posts
    523
    Originally posted by Enigma
    Does november contain 31 days ... hmm .. something is very wrong with your code
    this works :-
    select convert(datetime,'Nov 30, 2002 10:41PM',107)

    how foolish of me!!
    actually this was the input to a proc and the parameters were provided by the programmers, so i just tried to check with the same.
    nways thnxs.
    regards,
    harsh.

Posting Permissions

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