How to connect to a MySQL server with Delphi - mysql

I know how to use ODBC to connect to a MySQL database on the same machine, but now I want to know how to connect to a MySQL database on another server across the network.

Write the database computer's name or IP-address after Server= in the connection string.
For example:
Driver={MySQL ODBC 5.1 Driver};Server=myServerAddress;Database=myDataBase;User=myUsername; Password=myPassword;Option=3;
more examples here http://www.connectionstrings.com/mysql#p31

Related

Connecting VB.NET 2015 app to MySQL database

How do I connect MySQL database to a VB.NET 2015 application?
In order to connect to MySQL Database, you need to ensure below things:-
MySQL Connector is installed
https://dev.mysql.com/downloads/connector/net/
Define connection string as Server=myServerAddress;Database=myDataBase;Uid=myUsername;Pwd=myPassword;
Or consult following link to suit your situation http://www.connectionstrings.com/mysql-connector-net-mysqlconnection/
Rest is same as you work MSSQL or OleDB connections.

Connection failed in using mysqlconnector ODBC to connect from sql to access

I am trying to connect mysql database in phpmyadmin to the access file. I am using mysqlconnector ODBC for that. Tutorial I am following is this
The problem is that when I give the credentials to connect to database, it gives me error as shown in this snapshot
I have tried hard to search on internet but failed. What mistake I am doing. I am putting the ftp information of the server there. Is there any database credentials i need to put?
You can't use the FTP credentials to connect the MySQL database. You have to use the database credentials. Make sure you have done followings before connecting.
Make sure MySQL server is up and running on the HOST IP and PORT.
Your MySQL server can accept connections from your IP or use % for
all IPS
Make sure you have a valid USER account
EDIT
Or tell us where(local server, internet, IP) the MySQL database is installed. The port number the server is listening on. How you access MySQL server normally.

MYSQL ODBC adding server name to user name

Trying to create an ODBC connection from a server to MySQL server. installed 5.1 ODBC driver on the server I want to connect from. when I go to test the connection - the MySql server denies access to user -- then it lists the username with a "#servername.domain.com" appended to it. why is the ODBC appeneding that? so clearly we are connecting to the MySQL server. Both serers are in the same domain behind the firewall. is there somethign on the MySQL server need to configure?

Connecting a VB.NET 2010 app to a LAN Server MySql database

I want my vb application to communicate with a MySql database on server on a LAN. What connection string can i use? Also, what syntax can i use? My application is installed on many computers in LAN with one central MySql database. I want all data to go to the database.
For connection strings try connectionstrings.com (1st result when googling 'MySQL Connection String')

Connect to MySQL database on vb.net using dial-up connection

I want to connect to a MySQL database but the only connection available is a telephone line, a dial-up connection. I'm using vb.net 2005 Express for my project. All local connections are working the only problem is how can i get the server to connect, like IP to connect to establish a connection.
Thanks!