Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

connecting msccess to remote MySQL

Status
Not open for further replies.

oax2

IS-IT--Management
Dec 18, 2007
3
PH
Hi

Hi to all folks!

I have an msaccess2003 as the front end. Id like to connect my front end which is on my local pc to a remote MySQL hosted in a server.

for example : Database: accounts_rms
user: test
pwd: testpwd

How do I connect using this infos? And where should I load the connection string? during Form.load? or can I be through ODBC? I have already installed the mysql driver in my local PC.

Any helps or ideas would be greatly appreciated.

Thanks in advance

mybers
 
Using the sample data you provided, the following ODBC connection string should work to connect your front end to the remote MySQL backend:
Code:
ODBC;
Driver={MySQL ODBC 3.51 Driver};
Server=mysql.frontpos.com;
Port=3306;
Database=accounts_rms;
User=test;
Password=testpwd;
Option=3;
Here are the bit values and definitions for the Option parameter:
Code:
1 - Client Can't handle the real column width being returned.

2 - Have MySQL return found rows value.

8 - Allow Big Values: We want the server to send out the BLOB values to our VB client (large packets), so this option must be set.

32 - Toggle Dynamic cursor support.

16384 - Convert LongLong to Int: This just helps makes sure that large numeric results get properly interpreted.
 
I don't see option 3 listed but that's the one you've selected? What does option 3 do?

Thanks!

leslie
 
Option 3 is a combination of the first two option bits:

1 OR 2 = 3


If I wanted to add option bit 8 to this parameter value, it would be:

1 OR 2 OR 8 = 11

...so the related part of the connection string would read:
Option=11;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top