asp.net consultancy chorley ASP.NET Server Side Scripting Wigan
Website Development Radcliffe

IT Services And Support

Email : ren@techsolus.co.uk
Mobile Phone : 0788 68 41 411
Answerphone : 01204 469683
bespoke invoice systems Standish Information Technology Advice Worsley
    development systems Ramsbottom
data manipulation Farnworth access databases Whitefield SQL connections Atherton
online accessible software Leyland software compatible Coppull


Get connected and Online Tottington
remote management Makerfield code and design Aspull

Start AutoNumber From 'x' and not 0 - Access SQL - 07/06/2012

Short n sweet...

Use an "INSERT INTO..." statement that also sets the autoincrement/autonumber field, for example

INSERT INTO mytable (myfield1, myfield2, myfield3, myautonumber) VALUES ('This', 'is', 'Easy', 5000)

This will insert into the table a new record with the autoincrement/autonumber at a certain vaule, in this case 5,000.  Access will continue to count from this number upwards.  If you don't want the first record, delete it...

I used MS Access 2003 to do this with my web based database.  I created a query and ran it.  I have no reason to doubt that it will work if I'd done a straight SQL query from ASP.Net, it was just easier to use Access.

Post A Comment

Name Comment
programming services asp.net specialist
Valid XHTML 1.0 Transitional
Admin
GD