autonumber

  • Thread starter Thread starter Tony Palermo
  • Start date Start date
T

Tony Palermo

I have created a table and would like to have the
autonumber in their to use for a sort. there are 5
columns in the table one of which is the autonumber which
is in the last spot. i just want to know if there is a
way to insert into the table the other 4 variables
without having to physically send the autonumber too. i
have tried the following statement and it did not work.
please help

insert into tablename (column1, column2, column3,
column4) values (variable1,variable2,variable3,variable4)
this will not work cause the autonumber is the fifth
column and i am not passing any value for it. please
please help
 
The next available value of the autonumber will be created automaticaly. You
do not have to send it in there.

Why did your INSERT statement not work? Show us the statement code, & the
error number & message you got.

HTH,
TC
 
i just want to know if there is a
way to insert into the table the other 4 variables
without having to physically send the autonumber too.

No: the "auto" part of Autonumber means that it provides the next number
automatically. If you really want to remove a value from an autonumber
field (i.e. set it to Null), you can probably do it with an UPDATE query,
although I am sure you cannot do it in the UI or with vba code.

Mind you, I cannot imagine why you would want to do this. The only thing
that an AN does is to provide a unique number for each record. If you set
the value to "unknown" (which is what Null means), then it won't be unique
any more.

More information please?


Tim F
 
Back
Top