Results 1 to 2 of 2

Thread: 1/1/1900

  1. #1
    Rob Guest

    Default 1/1/1900

    You would not believe how many people i have asked this question to.<BR><BR>Whenever I try to insert a blank value for a date in SQL server 7, I<BR>get the default of 1/1/1900. I have tried religiously to stop this from happening.<BR>Including doing the below before INSERT.<BR><BR>HOW DO I DO IT?<BR><BR>recDate = request.form("recDate&")<BR><BR>if recDate = "" then<BR><BR>recDate = "NULL"<BR><BR>End If<BR><BR>

  2. #2
    SPG Guest

    Default RE: 1/1/1900

    Assuming that your db has "allow null" on the date column, I&#039m afraid the news is that you can&#039t. It&#039s a wierd glitch with Microsoft databases (Access, too) -- whenever a date Can Not Be, it Is 1/1/1900.<BR><BR>Substantially confused me the first time I ran into it (malformed date; was my fault).<BR><BR>If you can get away with it, you might want to convert your date field to just a varChar field. Alternately, hope that nobody will mind you counter-declaring 1/1/1900 to be NULL when getting information from the database.

Posting Permissions

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