Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
Is it possible to run a FoxPro database in Linux? I have heard of emulators such as Wine, and VMware. I am a linux newbie, but I am curious to seee if I can make this work. I am running Red Hat 7.2 setup as a server with command prompt input only. How would I be able to run the database form the Red hat server and have Windows clients access the database on the server. What are the first steps I need to take? Your help is greatly appreciated.

That's easy. Foxpro databases are just data. They can be put anywhere if your program is smart enough to find them. Put the data on the server and have the windows clients reference it. No worries. A few minor problems:
Linux uses samba to connect to windows computers. Samba is slightly more complicated than right clicking on a drive and selecthing "Sharing..." A good book on samba can be found in (most) any Barnes & Noble or whatever large book store you have that might sell computer books. It's probably unnecessary. Samba is set up with a text file. Just follow the examples (a good distro will have them).
Things to watch out for with foxpro:
- Any path with a space in it will cause Foxpro problems because of statements like:
APPEND FROM &filename TYPE DELIMITED
Why FoxPro can't treat variables like variables, I don't know. It expects a DOS environment where all data locations are predefined. Quotes will solve the problem of having a space in the path or file name. (I say this because I got caught with this problem today. Suck.) Linux makes full use of long file names because it doesn't use a FAT file system. A unix file type is specified it its permissions (DRWX), not its extension.
- Make sure you give the user write permissions or have some facility to recognize read-only databases. (I got caught with this error too.) If you aren't using samba as a login server, all users will be admitted as "nobody," a user with very minimal permissions.
- If you use forms with a data environment, make sure you put your data in exactly the place the data environment specifies. You will either get errors if it can't find the data or other weirdness if it finds something it shouldn't be looking at. The simple way to get around this is to explicitly open the data yourself and let your forms find what you opened. It makes coding more difficult, but in the long run it's more flexible. (gcDataDir is a nice variable.)

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |