Access 2010 table field default value problem?


  • Hi all,

    I have application built in microsoft office access adp. It worked fine in access 2003 and 2007, but now i have problem with access 2010. I have some columns in table that have default values. In access 2003 and 2007 when insert new row, that fields with default values are automatically filed with default values and I don't need to fill them. In access 2010 only fields that allow null values are filed, but fields that not allows nulls are not filled automatically. Same problem occurs if i insert row through form or manually in table.

    I don't know if this is bug or I have to take care of this fields through code or just have some parameter to turn this on so it can be filled automatically.

    I use microsoft office access 2010 and sql server 2005 developer edition sp3. I've already installed all patches. Sql is not problem because other users who connect to sql with office 2003 and 2007 don't have this problem.

    Any help would be appreciated.


    Tuesday, January 25, 2011 3:37 PM

All replies

  • I have exactly the same problem.

    I'm using SQL-Server 2008 as the back-end. 

    If I create an access.adp in 2007 , and just open a table, when I go to New Record, all of the column default values are retrieved

    If I create an access.adp in 2010 , and just open a table, when I go to New Record, NONE of the default values are retrieved .

    What the??? !!!

    Friday, February 18, 2011 10:00 PM
  • Did some more investigating, and what I found was that:

    in an Access 2007 .adp, when you navigate to a New Record, the table column default values are pre-populated.  (they are retrieved even before you begin to enter any data.)
    HOWEVER, in Access 2010, the table column default values are not populated until AFTER THE RECORD IS WRITTEN!!
    This means that tests against the default values of columns or controls will fail for new records.
    The work-around is to hard code the default values into the form controls properties. 

    I wonder whose brilliant idea THAT was?

    Friday, February 18, 2011 10:26 PM