How to INSERT null values into MS ACCESS from ASP?


DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 3 of 3

Thread: How to INSERT null values into MS ACCESS from ASP?

  1. #1
    Hema Kumar Guest

    How to INSERT null values into MS ACCESS from ASP?


    Is NULL reserve word in ASP? Can MS ACCESS accept NULL values?
    I am using INSERT statement in ASP to add a row with 10 fields. Some times
    user may not enter values for one or two fields. In that case my INSERT statement
    will have empty values for those fields. It is giving error. How to solve
    this problem? Can somebody give my small syntax?


  2. #2
    Douglas J. Steele Guest

    Re: How to INSERT null values into MS ACCESS from ASP?

    It depends on whether your fields have been set up to allow Nulls.

    If they have, then simply leave the fields out of your INSERT statement.
    Failing that, assign the fields the literal Null, as opposed to the variable
    you're got.

    --
    Doug Steele, Microsoft Access MVP
    http://I.Am/DougSteele


    "Hema Kumar" <hemakumar65@hotmail.com> wrote in message
    news:3ccac3ca@10.1.10.29...
    >
    > Is NULL reserve word in ASP? Can MS ACCESS accept NULL values?
    > I am using INSERT statement in ASP to add a row with 10 fields. Some times
    > user may not enter values for one or two fields. In that case my INSERT

    statement
    > will have empty values for those fields. It is giving error. How to solve
    > this problem? Can somebody give my small syntax?
    >




  3. #3
    ICE Guest

    Re: How to INSERT null values into MS ACCESS from ASP?



    You may want try to form validation prior to the page where you preform the
    insertion, in that way, you are sure the either the user enter some value
    or you can default the value itself.

    "Hema Kumar" <hemakumar65@hotmail.com> wrote:
    >
    >Is NULL reserve word in ASP? Can MS ACCESS accept NULL values?
    >I am using INSERT statement in ASP to add a row with 10 fields. Some times
    >user may not enter values for one or two fields. In that case my INSERT

    statement
    >will have empty values for those fields. It is giving error. How to solve
    >this problem? Can somebody give my small syntax?
    >



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center
 
 
FAQ
Latest Articles
Java
.NET
XML
Database
Enterprise
Questions? Contact us.
C++
Web Development
Wireless
Latest Tips
Open Source


   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center