How do I connect to a mysql database thats on a server? Im using vb .net 2005. Thanks
Printable View
How do I connect to a mysql database thats on a server? Im using vb .net 2005. Thanks
See www.connectionstrings.com for all manner of connection string formats, including the one you want.
Do I need to use a special control?
There are no controls involved. Controls are UI elements.
You use the standard ADO.NET methodology using a data namespace that can access MySQL. You can use System.Data.Odbc, which is part of the .NET Framework, or you can use a third-party library that is designed specifically for MySQL. I'd suggest the latter, and there is such a library available free from MySQL themselves.
Once you've decided on the namespace you perfrom the standard ADO.NET operations. If you use the MySQL library you'll be using a MySqlConnection, MySqlDataAdapter, etc. I'd suggest that you read some ADO.NET tutorials to get the basic principles. Any tutorial will do as the principles are the same no matter the data source. For instance, you can read the tute from fellow member TechGnome's signature. It's designed for SQL Server but all you have to do is change SqlConnection to MySqlConnection, etc., get the right connection string format and you're away.
Thanx for the info, you are the man