By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,222 Members | 1,730 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,222 IT Pros & Developers. It's quick & easy.

Error "Could not save; currently locked by another user."

P: n/a
One of our application uses VB6 and Access97 database. Another application
uses VB.NET 2005.
This morning for about 15 seconds when the application tries to read either
a query or a table from the database, in in both VB6 and VB.NET
applications, I got the error "The Microsoft Jet database engine cannot find
the input table or query 'myTable'. Make sure it exists and that its name
is spelled correctly." Also, I got the error "The Microsoft Jet database
engine cannot find the input table or query 'myQuery'. Make sure it exists
and that its name is spelled correctly." The error happens to all the tables
and all the queries.
Also, the VB.NET application (uses OLEDB) got an error when trying to open a
table "Could not save; currently locked by another user."
Then, after the 15 seconds or so, everything worked fine again.

What would cause the above errors ? Why couldn't it recognize the existing
tables and queries for about 15 seconds ?

Thank you.
Sep 10 '08 #1
Share this Question
Share on Google+
11 Replies


P: n/a
Was anyone modifying the table itself - or had the table opend up in design
mode with access?
Access would lock the mdb file on you like that I believe.

Might be a good test - log everyone out - go into access and open up the
file, abnd a table and then try to run your program.
Someone may have inadvertantly run something thru microsoft word or
something against your table?
"fniles" <fn****@pfmail.comwrote in message
news:eR**************@TK2MSFTNGP04.phx.gbl...
One of our application uses VB6 and Access97 database. Another application
uses VB.NET 2005.
This morning for about 15 seconds when the application tries to read
either a query or a table from the database, in in both VB6 and VB.NET
applications, I got the error "The Microsoft Jet database engine cannot
find the input table or query 'myTable'. Make sure it exists and that its
name is spelled correctly." Also, I got the error "The Microsoft Jet
database engine cannot find the input table or query 'myQuery'. Make sure
it exists and that its name is spelled correctly." The error happens to
all the tables and all the queries.
Also, the VB.NET application (uses OLEDB) got an error when trying to open
a table "Could not save; currently locked by another user."
Then, after the 15 seconds or so, everything worked fine again.

What would cause the above errors ? Why couldn't it recognize the existing
tables and queries for about 15 seconds ?

Thank you.

Sep 10 '08 #2

P: n/a
On Wed, 10 Sep 2008 09:49:59 -0500, "fniles" <fn****@pfmail.comwrote:

One of our application uses VB6 and Access97 database. Another application
uses VB.NET 2005.
This morning for about 15 seconds when the application tries to read either
a query or a table from the database, in in both VB6 and VB.NET
applications, I got the error "The Microsoft Jet database engine cannot find
the input table or query 'myTable'. Make sure it exists and that its name
is spelled correctly." Also, I got the error "The Microsoft Jet database
engine cannot find the input table or query 'myQuery'. Make sure it exists
and that its name is spelled correctly." The error happens to all the tables
and all the queries.
Also, the VB.NET application (uses OLEDB) got an error when trying to open a
table "Could not save; currently locked by another user."
Then, after the 15 seconds or so, everything worked fine again.

What would cause the above errors ? Why couldn't it recognize the existing
tables and queries for about 15 seconds ?

Is this a multi-user database located on a network or is it a single user database on a local
machine?
Paul
~~~~
Microsoft MVP (Visual Basic)
Sep 10 '08 #3

P: n/a
It's a multi user database located on a network.

"Paul Clement" <Us***********************@swspectrum.comwrote in message
news:m8********************************@4ax.com...
On Wed, 10 Sep 2008 09:49:59 -0500, "fniles" <fn****@pfmail.comwrote:

One of our application uses VB6 and Access97 database. Another
application
uses VB.NET 2005.
This morning for about 15 seconds when the application tries to read
either
a query or a table from the database, in in both VB6 and VB.NET
applications, I got the error "The Microsoft Jet database engine cannot
find
the input table or query 'myTable'. Make sure it exists and that its
name
is spelled correctly." Also, I got the error "The Microsoft Jet database
engine cannot find the input table or query 'myQuery'. Make sure it
exists
and that its name is spelled correctly." The error happens to all the
tables
and all the queries.
Also, the VB.NET application (uses OLEDB) got an error when trying to
open a
table "Could not save; currently locked by another user."
Then, after the 15 seconds or so, everything worked fine again.

What would cause the above errors ? Why couldn't it recognize the
existing
tables and queries for about 15 seconds ?

Is this a multi-user database located on a network or is it a single user
database on a local
machine?
Paul
~~~~
Microsoft MVP (Visual Basic)

Sep 10 '08 #4

P: n/a
>Someone may have inadvertantly run something thru microsoft word or
>something against your table?
What did you mean by run something thru microsoft word ?
"Miro" <mi**@beero.comwrote in message
news:uf**************@TK2MSFTNGP03.phx.gbl...
Was anyone modifying the table itself - or had the table opend up in
design mode with access?
Access would lock the mdb file on you like that I believe.

Might be a good test - log everyone out - go into access and open up the
file, abnd a table and then try to run your program.
Someone may have inadvertantly run something thru microsoft word or
something against your table?
"fniles" <fn****@pfmail.comwrote in message
news:eR**************@TK2MSFTNGP04.phx.gbl...
>One of our application uses VB6 and Access97 database. Another
application uses VB.NET 2005.
This morning for about 15 seconds when the application tries to read
either a query or a table from the database, in in both VB6 and VB.NET
applications, I got the error "The Microsoft Jet database engine cannot
find the input table or query 'myTable'. Make sure it exists and that
its name is spelled correctly." Also, I got the error "The Microsoft Jet
database engine cannot find the input table or query 'myQuery'. Make
sure it exists and that its name is spelled correctly." The error happens
to all the tables and all the queries.
Also, the VB.NET application (uses OLEDB) got an error when trying to
open a table "Could not save; currently locked by another user."
Then, after the 15 seconds or so, everything worked fine again.

What would cause the above errors ? Why couldn't it recognize the
existing tables and queries for about 15 seconds ?

Thank you.


Sep 10 '08 #5

P: n/a
I beleive Microsoft word treats mdb files like excel when you start using
them as a data source for data.

It locks the file and makes a file.
just like if you had a pure excel file - and open it...it creates like a
2ndary file of it. Once you close excel the 2ndary temp file disappears.
But the whole file is locked until you do.

Someone could be running something on your file thru excel or word perhaps?

It is a file on the network - thus giving everyone full rights to the file,
and you are trusting the do not go to the file and hit 'delete' or
'whatever' to it.

I am assuming you are under the assumption that the users only use your
'program' to access the data.
That assumption may be incorrect. ( If my first assumption is true :-) )

One easy idea might be to rename the mdb file to be something like
yourfilename.bla and let your program open the file.
That way if someone tries to look for mdb files to open with word, it
searches for *.mdb and it wont come up. They will have to know your 'bla'
file is an mdb file and change the search to *.* and select it. Of course -
then you are in the same boat, but it might help you find out if someone is
using an external program to access the access database.
If you change the file name...someone ( if inderectly using the access
table ) without knowing it... might ask a question like "my program stopped
working/ my word document / my excel"

Just a thought. But again - i could be totally off and I could be leading
you down the wrong path.

It may be something totally not related...but my first assumption would be
that someone did have that 'file' locked thru another program.
Perhaps ask the users what else they are running and see if something pops
up?

"fniles" <fn****@pfmail.comwrote in message
news:%2****************@TK2MSFTNGP03.phx.gbl...
Someone may have inadvertantly run something thru microsoft word or
something against your table?
What did you mean by run something thru microsoft word ?
"Miro" <mi**@beero.comwrote in message
news:uf**************@TK2MSFTNGP03.phx.gbl...
>Was anyone modifying the table itself - or had the table opend up in
design mode with access?
Access would lock the mdb file on you like that I believe.

Might be a good test - log everyone out - go into access and open up the
file, abnd a table and then try to run your program.
Someone may have inadvertantly run something thru microsoft word or
something against your table?
"fniles" <fn****@pfmail.comwrote in message
news:eR**************@TK2MSFTNGP04.phx.gbl...
>>One of our application uses VB6 and Access97 database. Another
application uses VB.NET 2005.
This morning for about 15 seconds when the application tries to read
either a query or a table from the database, in in both VB6 and VB.NET
applications, I got the error "The Microsoft Jet database engine cannot
find the input table or query 'myTable'. Make sure it exists and that
its name is spelled correctly." Also, I got the error "The Microsoft Jet
database engine cannot find the input table or query 'myQuery'. Make
sure it exists and that its name is spelled correctly." The error
happens to all the tables and all the queries.
Also, the VB.NET application (uses OLEDB) got an error when trying to
open a table "Could not save; currently locked by another user."
Then, after the 15 seconds or so, everything worked fine again.

What would cause the above errors ? Why couldn't it recognize the
existing tables and queries for about 15 seconds ?

Thank you.


Sep 10 '08 #6

P: n/a

"fniles" <fn****@pfmail.comwrote in message
news:eR**************@TK2MSFTNGP04.phx.gbl...
One of our application uses VB6 and Access97 database. Another application
uses VB.NET 2005.
This morning for about 15 seconds when the application tries to read
either
a query or a table from the database, in in both VB6 and VB.NET
applications, I got the error "The Microsoft Jet database engine cannot
find
the input table or query 'myTable'. Make sure it exists and that its name
is spelled correctly." Also, I got the error "The Microsoft Jet database
engine cannot find the input table or query 'myQuery'. Make sure it
exists
and that its name is spelled correctly." The error happens to all the
tables
and all the queries.
Also, the VB.NET application (uses OLEDB) got an error when trying to open
a
table "Could not save; currently locked by another user."
Then, after the 15 seconds or so, everything worked fine again.

What would cause the above errors ? Why couldn't it recognize the existing
tables and queries for about 15 seconds ?
Most likely a temporary 'dead-lock'.

There may be something useful in these articles:

"How to keep a Jet 4.0 database in top working condition"
http://support.microsoft.com/kb/303528/

"Introduction to .ldb files in Access 2000"
http://support.microsoft.com/kb/208778

-ralph
Sep 10 '08 #7

P: n/a
On Wed, 10 Sep 2008 14:09:09 -0500, "fniles" <fn****@pfmail.comwrote:

It's a multi user database located on a network.


Do all users have full permissions to the folder where the database is located?
Paul
~~~~
Microsoft MVP (Visual Basic)
Sep 10 '08 #8

P: n/a
You can view which user has the file open on shared folders by using
"Computer Management" in Control Panel, or "NET FILE" from the command line.
You can obtain the same information by calling NetFileEnum. Here is a VB6
sample that shows how to call that function:

http://vbnet.mvps.org/code/network/netfileenum.htm
Sep 10 '08 #9

P: n/a
"Full permissions" means permission to rename and delete the file ?
I am not sure.

"Paul Clement" <Us***********************@swspectrum.comwrote in message
news:eq********************************@4ax.com...
On Wed, 10 Sep 2008 14:09:09 -0500, "fniles" <fn****@pfmail.comwrote:

It's a multi user database located on a network.


Do all users have full permissions to the folder where the database is
located?
Paul
~~~~
Microsoft MVP (Visual Basic)

Sep 11 '08 #10

P: n/a

"fniles" <fn****@pfmail.comwrote in message
news:%2****************@TK2MSFTNGP05.phx.gbl...
"Full permissions" means permission to rename and delete the file ?
I am not sure.
Read/Write and Execute
Sep 11 '08 #11

P: n/a
On Thu, 11 Sep 2008 11:41:43 -0500, "fniles" <fn****@pfmail.comwrote:

"Full permissions" means permission to rename and delete the file ?
I am not sure.

Delete and create on the folder would be required because of the associated .LDB file that is
created/deleted when the database is opened/closed.
Paul
~~~~
Microsoft MVP (Visual Basic)
Sep 12 '08 #12

This discussion thread is closed

Replies have been disabled for this discussion.