Results 1 to 3 of 3
  1. #1
    Join Date
    Jul 2004

    Unanswered: Date input error

    Dear experts,

    I have a problem with my ASP program. I have a date field which required users to input the date and the date value will then stored in the Access DB. But I found that during the action of "INSERT", the month and the day of the date field will be swapped. But it wil be fine if the day of the date larger than 12. I am sure the date format in the form is consist with the date format in the DB. So, I cannot identify the problem. Can someome help me?

    Thanks a lot.


  2. #2
    Join Date
    Sep 2003
    The extremely Royal borough of Kensington, London
    The application is not important in this case.

    Access stores the date as mm/dd/yyyy.
    Bessie Braddock: Winston, you are drunk!
    Churchill: And Madam, you are ugly. And tomorrow, I'll be sober, and you will still be ugly.

  3. #3
    Join Date
    Apr 2002
    Toronto, Canada
    Quote Originally Posted by r123456
    Access stores the date as mm/dd/yyyy.
    actually, access stores a date value as a whole integer

    the format matters only when interpreting a date string

    when there is ambiguity, access assumes mm/dd/yyyy

    for example, if you insert 03/04/2005 this will be interpreted as march 4 because it could be ambiguous

    31/10/2005 is not ambiguous so it is interpreted as dd/mm/yyyy

    there is never ambiguity when using date strings formatted to the ISO standard, yyyy-mm-dd | @rudydotca
    Buy my SitePoint book: Simply SQL

Posting Permissions

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