VS2010 Program won't connect to MYSQL from local SQL Server Computer

0

my problem here is very weird compared to other that I found on this forum. The VB program is created with VS2010 from computer "A". It work perfectly. Connection to SQL Server and MYSQL DB. But when I copy the whole file to computer "B" where SQL Server is installed and is used by the program I mentioned before. SO I open with the VS 2010 and debug the program. This time the program can't connect to database. Error " No connection to database. Error trying to connect to user "user" ". Where "user" is the name of user.

FYI, everything maintain the same, IP, username, password, database. Only the location I open the proggram. Besides, I also check the firewall, mssql,ssma but still no connection.

What could cause this type of problem? Thanks in advance.

dswong

Posted 2013-06-14T08:55:23.677

Reputation: 101

You may need to change the IP to localhost. – NickW – 2013-06-14T09:05:10.867

Still the same problem. No connection to Db. :( – dswong – 2013-06-14T09:17:00.503

So, do you get a particular error number back? – NickW – 2013-06-14T09:31:48.930

Also, the user you added to MySQL, it should be user @ <somehost> what host did you add? Also, what are you using, MySQL or SQL Server? – NickW – 2013-06-14T09:38:43.577

yes its this. "no connection possible to DB: an error link to network or specific authorisation when trying to make a connection to sql server. The server is unavailable or inaccessible.Verify that the name is correct and the server is configure to authorise distance connection.(provider: Named Pipes Provider,error: 40-Impossible open a connection to sql server)". that is the error box. But I still don't get the reason why. – dswong – 2013-06-14T09:46:19.947

So, on one server you say MySQl, on the other SQL server.. which is you are trying to connect to? – NickW – 2013-06-14T09:58:54.600

actually the program uses both. sql server as main, and mysql as backup if anything when wrong. the user name is user and the db is mit but the specific hostname i'm not sure as isn't me that write the program. But I have acces to the SSMS. please guide me to solve the problem. thanks in advance. – dswong – 2013-06-14T09:58:55.057

Hmm, I know in mysql, you have three normal things that have to match for authentication to work. 1. user name 2. password. 3. host. I've had a look at SQL server, it doesn't seem to have the same sort of authentication system. You need to make sure that the user you are using to connect exists on server B, and has the access you need . It's not my forte' but there seems to be plenty of information about user management here: http://msdn.microsoft.com/en-us/library/bb545450.aspx

– NickW – 2013-06-14T10:04:20.323

Can you connect via SQL Management Studio from the SQL host machine using the connection settings and credentials the program uses? – Ƭᴇcʜιᴇ007 – 2013-06-14T12:21:17.707

I tried follow based on what i understand as i'm new in this type of stuff. Yes, theuser exist in the DB as i could connect to it from another computer. But what do you mean by SQL host machine using the connection settings and credentials the program uses ? I'm on the computer where the sql server is installed for the uses of the program that I'm having problem now. I can acces the SQL Management Studio. – dswong – 2013-06-14T14:11:55.430

No answers