Solved

How to access a MySQL database on an internet server?

Posted on 2007-11-26
12
226 Views
Last Modified: 2012-05-05
I have a C# program (desktop) that I want to access a web service.  That web service (also written in C#) needs to access a MySQL database sitting on the hosting server (a Windows server).  I imagine that connection string would have the site name(?) and database name, but haven't a clue how to put it together.

Can someone please give me a pointer to a doc or something?  
0
Comment
Question by:rmmarsh
  • 5
  • 5
12 Comments
 
LVL 55

Accepted Solution

by:
Jaime Olivares earned 500 total points
ID: 20354270
That's depend on the library you have choosen to access the MySql server. Have a look to:
http://www.connectionstrings.com/?carrier=mysql
0
 

Author Comment

by:rmmarsh
ID: 20354360
If I'm using the Visual Web Developer 2005, what choices do I have for a library?  I see the connection string is almost a no brainer, but still don't know what to use for the connection: ODBC?
0
 

Author Comment

by:rmmarsh
ID: 20354364
s/b Visual Web Developer 2005 *Express*
0
 
LVL 55

Expert Comment

by:Jaime Olivares
ID: 20354397
I mean, the mysql connection type: ODBC, OleDB, which have you selected?
The link I have posted give you connection string for all possibilities.
0
 

Author Comment

by:rmmarsh
ID: 20354410
Yes, it did... I guess I'll just pick one and see what happens... what do I put in the slot for "provider"?
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 55

Expert Comment

by:Jaime Olivares
ID: 20354457
in OleDB should be MySQLProv as shown.
0
 

Author Comment

by:rmmarsh
ID: 20354466
OK... how does it know where the database is?  (ie the host name?)

R
0
 
LVL 55

Expert Comment

by:Jaime Olivares
ID: 20354530
if you are using OleDB (I have this not clear until now), you define a connection in the Windows Control Panel, specifying URL, servername, port, etc.
This connection has a name, this is the name you use in the DataSource field.
0
 

Author Comment

by:rmmarsh
ID: 20354561
I'm using ODBC... give me a few days to figure this out (have to work the remainder of the week, so only work on this in my spare time)...

Thanks for your help so far...

R
0
 
LVL 18

Expert Comment

by:vbturbo
ID: 20356136
Hi

I you work alot with mysql then this would might be worth to consider

http://www.crlab.com/mysqlnet/

vbturbo
0
 
LVL 55

Expert Comment

by:Jaime Olivares
ID: 20552830
Still waiting for author response...
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Entity Framework is a powerful tool to help you interact with the DataBase but still doesn't help much when we have a Stored Procedure that returns more than one resultset. The solution takes some of out-of-the-box thinking; read on!
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
Both in life and business – not all partnerships are created equal. As the demand for cloud services increases, so do the number of self-proclaimed cloud partners. Asking the right questions up front in the partnership, will enable both parties …
As a trusted technology advisor to your customers you are likely getting the daily question of, ‘should I put this in the cloud?’ As customer demands for cloud services increases, companies will see a shift from traditional buying patterns to new…

920 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

17 Experts available now in Live!

Get 1:1 Help Now