Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Easy step to connecting to Mysql table?
Message
From
26/06/2009 20:15:57
 
 
To
26/06/2009 18:13:56
Mark Phillips
Erw Custom Programming Inc.
Waterford, Michigan, United States
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP1
OS:
Vista
Network:
Windows XP
Database:
MySQL
Application:
Web Service
Miscellaneous
Thread ID:
01408755
Message ID:
01408764
Views:
58
>Hello,
>
>I would like to connect to a MySql table on my site using VFP 9. I have no experance in doing this so I need an easy way to connect, browse, and maybe download info into a local VFP database. Any help you can give me would be great and THANK YOU for taking the time to help me with this....

From VFP, you can use either ODBC or OLEDB to connect to the MySQL server.

ODBC: you would use ODBC-related VFP commands such as SQLSTRINGCONNECT() to create a cursor or remote view into the MySQL data.

OLEDB: same basic idea but you do it via a VFP CursorAdapter.

Read the VFP help on remote views or CursorAdapters for an overview of what you need to do.

Some reference connection strings at http://connectionstrings.com/mysql

You'll probably want to use either the MySQL Connector/ODBC 3.51 or MySQL Connector/ODBC 5.1 for ODBC. For OLEDB you'll probably use MySQL OLEDB.

- Make sure the MySQL server is configured to accept ODBC or OLEDB requests
- Make sure the MySQL TCP/IP port is not firewalled off on the server machine (default appears to be port 3306)
- Install the appropriate ODBC or OLEDB provider on the same machine as VFP

- In your connection string(s) you may need to use just the server's name (i.e. NetBIOS computer name) or, if MySQL supports named instances and the MySQL server process is a named instance, you may need to specify a name something like ServerComputerName\MySQLInstanceName.
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform