Solved

Connecting to SQL Server database in Codecharge studio

Posted on 2013-12-05
4
897 Views
Last Modified: 2013-12-12
Hi,

I'm trying to connect to a database in Microsoft SQl server 2012 in Windows_NT mode.

The database name is "Checkweigher" and is setup in mixed mode.

I''ve setup the Codecharge studio connection.

Database: SQL Server
Server Name: ***\MES
Selected use Windows NT Integrated security
And selected the database.

I tested the connection and it says that the connection was successful

 But when I click on the "Live Page: tab, I get the following error:

Unable to establish connection to database.
Error information:
Microsoft OLE DB Provider for SQL Server (0x80004005)
Cannot open database "CheckWeighers" requested by the login. The login failed.
Other possible cause of this problem:
The database cannot be opened, most likely due to incorrect connection settings or insufficient security set on your database folder or file.
For more details please refer to http://support.microsoft.com/default.aspx?scid=kb;en-us;Q306518

I just can't seem to find a solution. Please help.

Thanks.
0
Comment
Question by:Buddhi_imatrix
  • 2
4 Comments
 
LVL 32

Expert Comment

by:Big Monty
ID: 39703619
usually when you get this message, it's due to the connecting user not having enough rights to the database. Are you sure you're using the same user as when you initially tested the connection?

it may also be trying to connect via your IIS user (I've run into setups like these), try giving your IIS user full rights (just as a test) and see if that helps.
0
 
LVL 28

Accepted Solution

by:
sammySeltzer earned 500 total points
ID: 39713125
Yes, The_Big_Daddy is correct.

Open SQL Server Management Studio (SSMS),
Right-click on the database in question
Click on Properties
Click on Permissions
Then if you don't see the user there, click Add
Click Browse
Look for the login name you created
Finally, check Execute.

If the login isn't already created, then create it first.
0
 

Author Comment

by:Buddhi_imatrix
ID: 39715541
Thanks guys!!... i tried to pin point the problem so i deleted all the permission I had given it but it still works. Seems a bit weird.
0
 
LVL 32

Expert Comment

by:Big Monty
ID: 39715562
No split in the points? I provided the overall theory in the answer and SS provided the fix. Not sure how you came about your awarding of points on this one....
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

I have helped a lot of people on EE with their coding sources and have enjoyed near about every minute of it. Sometimes it can get a little tedious but it is always a challenge and the one thing that I always say is:  The Exchange of information …
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now