News Promotions2
logo CODEWARE
Homepage Label and card printing Solutions Blog Service Centre

FoxPro databáze
KB0003

Komunikace s databází FoxPro pomocí ODBC

1. Install the driver for Microsoft Visual FoxPro (VFPODBC.msi)

2. Create a new one in the ODBC sources using "Microsoft FoxPro VFP Driver (*.dbf)"
Enter the name of the data source
Select Free Table Directory (if these are standalone DBF files)
Set the path to the directory with the DBF files in the "Path" field

3. Read from the database using
select ... from file_name_without_.DBF

4. If it is necessary to read from several tables that are not in the same directory, the last one is set in the "Path" of the ODBC source (point 2) common directory and the relative path to the tables is used instead of the plain name of the tables in the "select" statement:

The CENIK.DBF table is in C:\Prace\Ceny\2015
The table STAVSKLADU.DBF is in the folder C:\Prace\Cost\2015
The tables are bound by the column ID_COLLUMNS

The "Path" of the ODBC source is C:\Prace
Reading from the database is done using
select C.CODE, C.NAME, S.STATEFOLD from Ceny\2015\CENIK C, Sklad\2015\STAVSKLADU S where C.ID_ZBOZI=S.ID_ZBOZI

-MP-

Applies to:
logo