Auto number field in a Access database table

vinwin06

Registered User.
Local time
Today, 17:30
Joined
Sep 1, 2011
Messages
17
Hi All,
I need an help in creating auto number field in access database. Let me explain you further. I have an access database which 20 million records. When i am trying to add auto number field i am getting error "File sharing lock count exceeded".
Then i did some google search and got some infomation like editing the registry file , in my case its not possible due to security restrictions.
And another option of adding a code in VB immediate window also i tried but this option is also not working.

"DAO.DBEngine.SetOption dbmaxlocksperfile,25000000"
Can anyone help how to solve this issue else can you please help me on how to auto populate the numbers in a specific field using VBA codes.
Thanks in advance.
 
This might work:

1-Backup your database,
2-Add a field (MyID, autonumber) to the table involved
3-Save the table design


Tell us more about the database. Is it single user? Is it FE/BE?
 
I did that already while doing that only I am getting the error mentioned above.
 
Is this in a Jet Database?
If yes than I would say it's time to move to a Full SQL system. Like MySQL or SQL Server. Let the database handle its own management.

Start using Access as a front end.

20,000,000 probably means you are close to running out of file space.
 
yes I know I'm reaching around 1.5 GB now... its normal ms access database only. not SQL db.
 

Users who are viewing this thread

Back
Top Bottom