Default value for newly appended field 
Author Message
 Default value for newly appended field

If I append a field to an existing Table (with records) using DDL (Alter
Table command) or DAO, and specify a defaultvalue property for the newly
appended field, the value does not appear for the existing record, though it
does appear for the future records.

I believe in Transact-SQL,  Alter Table command's Default Value property
also applies to existing records.  Is there a similar functionality in
Access too or I would have to use an update statement to set the value as
default value for the newly appended field.

TIA,

Deep



Sun, 30 Sep 2001 03:00:00 GMT  
 Default value for newly appended field
Since you just proved it doesn't work, you answered your own question.
Just use an update query to go back and "fix" existing data.

Quote:

>If I append a field to an existing Table (with records) using DDL (Alter
>Table command) or DAO, and specify a defaultvalue property for the newly
>appended field, the value does not appear for the existing record, though
it
>does appear for the future records.

>I believe in Transact-SQL,  Alter Table command's Default Value property
>also applies to existing records.  Is there a similar functionality in
>Access too or I would have to use an update statement to set the value as
>default value for the newly appended field.

>TIA,

>Deep



Sun, 30 Sep 2001 03:00:00 GMT  
 Default value for newly appended field
Since you just proved it doesn't work, you answered your own question.
Just use an update query to go back and "fix" existing data.

Quote:

>If I append a field to an existing Table (with records) using DDL (Alter
>Table command) or DAO, and specify a defaultvalue property for the newly
>appended field, the value does not appear for the existing record, though
it
>does appear for the future records.

>I believe in Transact-SQL,  Alter Table command's Default Value property
>also applies to existing records.  Is there a similar functionality in
>Access too or I would have to use an update statement to set the value as
>default value for the newly appended field.

>TIA,

>Deep



Mon, 22 Oct 2001 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Default value for newly appended field

2. VB3 entering data to a newly appended field

3. Default field value from another field

4. Field required, and Field default value

5. Append Chunk Function never appends to memo field

6. Function from field default value

7. Set the default value for a field in a table with VBA

8. default field to value of previous record

9. Returning a field from a table as a default value in a form

10. Adding required fields with default values to existing tables

11. Default Field Value

12. VB3/Access 2 - Setting default value for added field

 

 
Powered by phpBB® Forum Software