Mysql Connection

The place for peer-to-peer support for developing client-server applications with VPME 9.1.

Mysql Connection

Postby icdev » Mon Jun 14, 2010 11:22 pm

What is the best way from VPME9.1 to connect to mysql server?

I can install mysql odbc connector on my machine, and then reference the odbc connection when creating a cursoradaptor, but this would entail installing mysql odbc on each client machine?

thanks,
Steve
icdev
 
Posts: 45
Joined: Mon Jun 14, 2010 5:44 pm
Location: Bedford, Texas

Re: Mysql Connection

Postby JoeLawson » Tue Jun 15, 2010 9:22 am

To connect a VFP cursoradapter or remote view to any backend database, you need the ODBC driver for that database.

That means that when you install the VFP frontend client on a computer to connect to the MySQL data, you need to make sure that the computer has the MySQL ODBC driver and you need to set up the connection as part of the installation.

An alternative would be to put the VFP frontend on the same server as the MySQL data and use Terminal Services to run the application from remote workstations. In this scenario, basically there's nothing to install on the workstations.

BTW, I recall you briefly mentioning that at some point you wanted to convert your application to use MySQL but you never indicated why you wanted to do that. What are your reasons?

Also, how many users will your converted application have and where will they be located in relation to the sever hosting the MySQL database?
Best,

Joe Lawson
ProMatrix
JoeLawson
 
Posts: 132
Joined: Sun Jun 06, 2010 8:18 pm

Re: Mysql Connection

Postby icdev » Tue Jun 15, 2010 9:34 am

We have a mixed environment at present, with a vpme application running our main database, pos and backoffice functions, web site )ecommerce) running a mixture of perl, mysql and many php backend routines to access the vfp live data to hook to the mysql server - I'm trying to clean it up a bit, not to mention our database size growing nicely - some files approx 1gb.

It is not a big deal to install the mysql odbc on each workstation, just looking at the options.

We have about 10 workstations accessing the vpme application, 11-12 if you count the php applications accessing the live data, by means of an odbtp application running on the linux server box. Our servers, linux etc are located in-house.

btw, it is nice to see you mix it up with linux, and php. It's a good path (imo).

Steve Graham
icdev
 
Posts: 45
Joined: Mon Jun 14, 2010 5:44 pm
Location: Bedford, Texas

Re: Mysql Connection

Postby icdev » Wed Jan 25, 2012 10:48 am

Just an FYI note,

In windows 7 make sure you set up c:\windows\SysWOW64\odbcad32.exe to manage 32 bit odbc data sources for 32bit drivers. Took me a while to determine why my promatrix app wasn't talking to mysql database. It wouldn't work with the 64 bit odbc driver, but does work fine with the 32 bit odbc driver.
icdev
 
Posts: 45
Joined: Mon Jun 14, 2010 5:44 pm
Location: Bedford, Texas

Re: Mysql Connection

Postby stecenko » Wed Jan 25, 2012 12:16 pm

Hi Steve,

You said you didn't want to install the ODBC on each workstation. If you need to install the runtime library, can't you build in the install of the ODBC at the same time?

Also, about c:\windows\SysWOW64\odbcad32.exe. You said to be sure to set it up. What is involved in this set-up. I'm using MySQL ODBC 5.1 Driver (the 32 bit version) and I don't remember doing anything odbcad32.exe.

Does the MySQL driver install take care of this?
Richard Stecenko
Interactive Computer Services Inc.
Victoria, British Columbia
204.453.2052
stecenko
 
Posts: 822
Joined: Mon Jun 21, 2010 8:06 pm
Location: Saanich, British Columbia

Re: Mysql Connection

Postby icdev » Fri Mar 23, 2012 1:36 pm

I just now looked at this post - sorry.

The windows 7 machine in question was a 64 bit version of windows, and when I went through the menus to install an odbc connection it was using the 64 bit odbc connection handler.

So I had to open the 32bit handler, and set up the connection and it works.

There are two different mysql odbc installations setups available, one for 64bit and one for 32 bit.

If there is another method, I'd be curious to know.

Maybe it is just my program that has aspects that only work in 32 bit mode - not sure.
-Steve
icdev
 
Posts: 45
Joined: Mon Jun 14, 2010 5:44 pm
Location: Bedford, Texas

Re: Mysql Connection

Postby stecenko » Fri Mar 23, 2012 2:33 pm

For MySQL you have to use the 32-bit ODBC driver.I'm not sure why that is.

Maybe because VFP is 32-bit so the connection from VFP to MySQL has to 32-bit a well. Just speculation on my part.
Richard Stecenko
Interactive Computer Services Inc.
Victoria, British Columbia
204.453.2052
stecenko
 
Posts: 822
Joined: Mon Jun 21, 2010 8:06 pm
Location: Saanich, British Columbia


Return to VPM Enterprise 9.1 - Client Server

Who is online

Users browsing this forum: No registered users and 1 guest

cron