beuki
beuki

Reputation: 90

How can I configure the MYSQL ODBC driver to work with Visual Studio 2013?

I've installed MYSQL server, running local on 127.0.0.1 (I've also tried this with MySQL server at a public IP with same results).

Here is how I'm configuring it:

Using MySQL Connector / ODBC (running localhost mysql server) using Visual Studio 2013 C#

I click Design tab of a webform.aspx page - and click and drag (from Toolbox->Data->GridView into the MainContent frame, and drop.

VisualBasic2013 gridview

I then click the [>] button Under Choose Data Source, I choose to create a new data source.

VisualBasic2013 Data Source Configuration Wizard

Under Data Source Configuration Wizard, I choose SQL Database.

Next pops up a window, Configure Data Source - SqlDataSource1

Configure Data Source

I click New Connection

Add Connection

Microsoft ODBC Data Source (ODBC) is selected as Data source - I leave it (note: here, I have tried changing this to MySql Data Source - but the connection fails). so I use the ODBC option.

I click the () Use Connection string: and click [Build]

Select Data Source

A window pops up, and I select the Machine Data Source tab

I have already created a Data Source named test_localhost_mysql, I select it.

Completed Data Source Information

A window with MySQL Connector/ODBC connection parameters appears, with all of my connection data. I click Test.

ODBC connection test success

success.

I click [OK]

Now, the Add Connection - Use connection string, is filled in, along with my login information.

I click Test Connection

Add Connection Test Success

Success.

I click [OK]

configuration wizard is now complete, and shows a string.

Configure Data Source complete

I click [NEXT]

save connection

I click [NEXT] without changing anything

Now is when it becomes interesting. on this screen;

data source configuration screen 3

under Specify columns from a table or view - all my tables are in the drop down list. Periodically, the columns will show here as well. Currently they aren't -- I'm sure this is not random, although I'm not sure what I'm doing to cause it.

I click [Next] after selecting my table.

data configuration test

I click [TEST]

data configuration test fails

It fails.

I am sure it's something simple, but I promise I've been through everything I can think of, and can really use some help please.

Anyone that can guide me I would greatly appreciate it.

I anxiously await your genious :) Thank you!

Upvotes: 0

Views: 5448

Answers (1)

Erik Russell
Erik Russell

Reputation: 881

Check this out. Try to install with the instructions here. Report back if the issue persists. http://www.w3resource.com/mysql/mysql-odbc-connection.php

EDIT: You also might want to run through all of your SQL code. It clearly says that the SQL syntax is not correct.

Upvotes: 1

Related Questions