![]() |
|
![]() |
![]() | Customer: Sign in Delegate: Sign in Trainer: Log in |
|
Forum home » Delegate support and help forum » Microsoft Access Training and help » Primary key - Appending and auto number to a set prefix Primary key - Appending and auto number to a set prefixThe UK's most regular instructor-led training courses.
Primary key - Appending and auto number to a set prefix
Nam has attended:
I have got 2 tables, tblClient and tblInvoicing on a one to many relationship respectively. How do I number my Invoice numbers (Primary ID field) such that they contain a prefix "PREM" then auto number of 6 fields e.g. PREM000001 for the first invoice number, PREM000010 for the tenth. How do I get the 4 letter prefix depending on the client e.g "PREM" for Premier, "CAST" for castlefield.
RE: Primary key - Appending and auto number to a set prefix
Hi Nam, Thank you for the post, welcome to the forum, in answer to your question, try this, create your database or amend your existing database, in the ID field which I assume you have as an Autonumber field, (remember you can only link an autonumber to a Double Integer field), in the Table design view, select the ID field and in the Format line of the field properties enter the following for your Premier Table.
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Mini sitemap. These are the main areas of our web site. Full sitemap.
| |||||||||||||||||||
© 2008 Best STL. All
Rights Reserved. A Microsoft software training company. info
All prices offered for business users and exclude VAT. E&OE · Terms
and Conditions