By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,335 Members | 1,791 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,335 IT Pros & Developers. It's quick & easy.

Connection to MYSQL

P: n/a
I am using the following code in Access 2k to establich a connection to a
MYSQL database

Dim conn As ADODB.Connection

Set conn = New ADODB.Connection

conn.ConnectionString = "DRIVER={MySQL ODBC 3.51 Driver};DESC=;USER=" &
myUsername_
& ";DATABASE=" & mySQLDatabase_
& ";SERVER=" & myServer_
& ";PASSWORD=" & myPassword_
& ";PORT=;OPTION=;STMT=;" ';TABLE=" & myTable
conn.Open

I get a Catostrophic failure error on the conn.Open line

This seems to work on one of my computers but not on the other. Both Windows
2K both accessing the same SQL database using the same username and password
Can anyone please help.
Alex
Nov 13 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Can you just do a quick test, and trying linking a table to MySql.

After you link...can you edit/view/use the table?

I would try and get a simple table link working. If you get that
working..then go back to trying your connection..
--
Albert D. Kallal (Access MVP)
Edmonton, Alberta Canada
pl*****************@msn.com
http://www.members.shaw.ca/AlbertKallal
Nov 13 '05 #2

P: n/a
I can connect to a table and edit it by linking it in Access using the
sameusername and password.
Alex

"Albert D. Kallal" <Pl*******************@msn.com> wrote in message
news:2NUJd.181844$8l.179345@pd7tw1no...
Can you just do a quick test, and trying linking a table to MySql.

After you link...can you edit/view/use the table?

I would try and get a simple table link working. If you get that
working..then go back to trying your connection..
--
Albert D. Kallal (Access MVP)
Edmonton, Alberta Canada
pl*****************@msn.com
http://www.members.shaw.ca/AlbertKallal

Nov 13 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.