Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Auto Num - Increment by 2 instead of 1

Status
Not open for further replies.

ajaeger

Technical User
Feb 6, 2003
201
US
Is there a way to create an auto num field and increment it by 2 instead of the default of 1?

Thanks.

Anna Jaeger
iMIS Database Support
 
Assume this is a table/form question not report.

Not autonumber but a field with
[tt]DMax("FieldName","TableName")+2[/tt]
many examples here in TT

________________________________________________________
Zameer Abdulla
Help to find Missing people
All cats love fish but fear to wet their paws..
 
Something like this (SQL code) ?
ALTER TABLE yourTable ADD COLUMN myAutoNum COUNTER(1, 3)

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
on the other side, WHY?

If it is just an "identity" field, or a variation on the theme of making an artificial field to assure uniqueness of the record, caring about the increment (of even type/character) is just a waste of resources.

I'm sure that you have a handy (and dandy) rationale for the 'requirement'. but think about it for a bit before re-inventing the process.

OBTW, your uniqueness gets to be a lot more of a chore when you have multiple users in the db, and that is more worthy of the attention.




MichaelRed


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top