Skip to content

Connect database(mysql) with other computer on ip number

ferhat gursu

Asked Mar 31, 2007, 2:21 AM EDT2 answers
Share
LinkedInX
i have a mysql database and i want to connect this database on other computer. i don't know how can i use c# command.

2 Answers

Know the answer? Post it. Somebody with the same question will find it here.

  • 0
    Hi! Firstly install MySql client on another machine. Then you can access the database by putting the ServerName as the first machine. i.e. only connection string is to be modified.
    0
  • 0
    Hi,

    string connectionString = "Data Source=201.70.128.58;database=jobs;User ID=User1;Password=cd5678;";
    SqlConnection conn = new SqlConnection(connectionString);

    The above code works with SQL Server. I have not tested with mysql.

    Learn Database programming
    0