July 20, 2009 at 9:06 am
Hi,
We are using SQL Server 2000 with Access 2000 VBA . One of our power users, gets random errors
'Can't find object... 'stfrmInsurance'. Then it throws him out of the system. When he logs back again it is fine and he cannot reproduce that error for some. The errors are random and not necessarily on the same stored procedure / or object.
Any help will be highly appreciated.
Martha S
July 20, 2009 at 9:11 am
ive seen this before...make sure that user has a specific default database for his login, instead of master. that database should be whatever database he's using for the application.
i think the issue is sometimes your connection switches to master(no proof, but maybe when you run a procedure from the master database, sp_help or whatever)
sometimes when his database context is master, the procedures or tables cannot be found, logging in again, this time with a connection string for the production db,then fixes it for a while\, until that wierd step, like calling something from master switches the context again.
Lowell
July 20, 2009 at 9:20 am
The User connects to the production database. There is only one database that the user connects and all tables & stored procedures are on that database ONLY. So there is no remote access. Master does not have any Sp or tables. How do I make sure that the database context does not switch.
July 20, 2009 at 9:35 am
SQLServerVBA (7/20/2009)
The User connects to the production database. There is only one database that the user connects and all tables & stored procedures are on that database ONLY. So there is no remote access. Master does not have any Sp or tables. How do I make sure that the database context does not switch.
yes, that is exactly my point. the user is expected to connect to one and only one database, but there is an occasional disconnect between the "default" database of a login, and the connection he was using...maybe it's due to connection pooling and timeouts, I'm not sure.
here is exactly what I'm talking about:
here, i created a user "bob", and he has permissions to only one database...but his default is "master"
that is where your issue exists, I think.
Lowell
July 20, 2009 at 11:44 am
Thanks for your reply. Should I change the User's default database as the Production database. Will this solve the problem.
Your time and suggestions are highly appreciated.
Martha
July 20, 2009 at 11:55 am
yes; like i had said before, I'd seen the issue in the past. I could never track down exactly what was the cause, but I found that changing that default to the production database resolved the issue for us;
The actual cause was always a lot of speculation, that ranged from the items i mentioned to people cooking fish in the microwave at work(yeah, we were that desperate to pin it on someone!)
you can search forro some other threads here on SSC on hte same issue, and I'm sure you'll see the smae solution suggested.
Good Luck!
Lowell
July 20, 2009 at 2:57 pm
Thanks for your suggestion. I am going to make this change and hopefully it will solve our problem.
July 28, 2009 at 9:25 am
Hi,
I made that change to the default database to USer Login from Master to production as you suggested and it solved the problem with the stored procedure not found errro but a different problem has surfaced.
DBnetlib connection write (Wrapper Write) General Network error.
Have you seen this error ? Any solution ?
Mary
Viewing 8 posts - 1 through 8 (of 8 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy