Solved

How VFP could access MySQL data at Apace ?

Posted on 2011-03-10
10
630 Views
Last Modified: 2012-05-11
Hi Experts !

Do you know a way VFP could access and persist data at a MySQL base that remains with Apache server ?
(preferencially with its native features)

Thanks in advance !
0
Comment
Question by:Eduardo Fuerte
  • 5
  • 3
  • 2
10 Comments
 
LVL 41

Accepted Solution

by:
pcelba earned 300 total points
ID: 35093498
Download and install MySQL ODBC Connector: http://dev.mysql.com/downloads/connector/odbc/

It will allow to connect MySQL database from anywhere on the Internet. You just have to provide IP address, User name and password.

More info: http://www.hentzenwerke.com/catalog/mysqlvfp.htm
0
 
LVL 29

Assisted Solution

by:Olaf Doschke
Olaf Doschke earned 200 total points
ID: 35093858
Correct. It does not matter where the database resides, on Windows or Linux Servers. VFP and the ODBC Driver need a Windows System, though. Also MySQL needs to be configured to allow remote access, that's not a default configuration. The Hentzenwerke book should cover that or ask in the MySQL section how to enable remote access and the consequences about security issues.

Bye, Olaf.
0
 

Author Comment

by:Eduardo Fuerte
ID: 35094076
Hello

In truth I have a PHP/MySQL site and a VFP system running DBF.

Since I don't want  to recriate VFP logical into PHP due its complexity and it's really not necessary since I could actualize it remotelly by VFP itself.

What I'd like is to maintain backoffice activities at VFP and front office activities at PHP, and time by time actualize MySQL >> DBF and DBF >> MySQL data - just when necessary.

According to your replies what I need is a very reasonable strategy, ok ?
What I'm planning Is it a common task ?
0
Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

 
LVL 41

Assisted Solution

by:pcelba
pcelba earned 300 total points
ID: 35094168
We don't know what data are on MySQL and what data are in DBFs...

Reasonable change would be to have data just in ONE place. OTOH, to write a simple program which will copy necessary data between DBFs and MySQL is easy. You just need a few SQL pass-through commands.

So, my recommendation: Store all data on MySQL only.
0
 

Author Comment

by:Eduardo Fuerte
ID: 35094311
So,  according to your reply the best approach is to actualize only MySQL database- remotelly.
The first step is to refator the persistence VFP class in that purpose.
Do you have any information about medium performance loss  ?- from local DBF to remote MySQL. (I  know it could vary to much from environment to environment but just a media).
0
 
LVL 41

Assisted Solution

by:pcelba
pcelba earned 300 total points
ID: 35096731
One database is better because the maintenance is easier. To update data between MySQL and VFP in both directions seems to be more complex. You have to decide what is worth for you.

The performance depends on the network speed, on the amount of data transferred, on number of processors, and on existing indexes etc. To create one test form should tell much more.
0
 

Author Comment

by:Eduardo Fuerte
ID: 35098724
Just for my knowledge. Putting DBF at Apache side to be accessed by PHP and VFP (at client side)could be a task reasonable done ?
0
 
LVL 29

Assisted Solution

by:Olaf Doschke
Olaf Doschke earned 200 total points
ID: 35100044
Yes, MySQL or any other remote database. The downside is the speed of the connection. As long as the MySQL Server is still in your offices LAN it will be comparably fast, if it's on a webserver connected via low bandwidth you might want to use the data syncing option.

Bye, Olaf.
0
 
LVL 41

Expert Comment

by:pcelba
ID: 35100064
You may access DBF on Apache server shared folder from Windows clients via ODBC or OLEDB only with all its disadvantages. Just try it and you'll see if it fullfil your needs.
0
 
LVL 41

Expert Comment

by:pcelba
ID: 35100118
Correction: VFP does not need ODBC (or OLE DB) driver when accessing DBF file on Apache server. It just needs the DBF in a shared folder accessisble from Windows.

PHP requires the connection to data, so it needs some driver.
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Microsoft Visual FoxPro (short VFP) is a programming language with it’s own IDE and database, ranking somewhat between Access and VB.NET + SQL Server (Express). Product Description: http://msdn.microsoft.com/en-us/vfoxpro/default.aspx (http://msd…
This problem is more common than not and I will show you some things to check to solve this problem.
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

778 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question