FLEX/ODBC Errors

There are many different types of errors returned by ODBC. The most common of which is the generic "Syntax Error". This typically means that your SQL query could not be parsed, possibly because of one of the following types of errors.

· ISAM Error
This most frequently occurs on files because the DAT file cannot be opened by the DFPATH you have given. Test your databases with our supplied Visual Basic or C++ test program before requesting support. You can also use the Trace option to see all operations by the driver and any DataFlex error codes encountered by the driver.

· Reserved words used as a field name or file name.
Check the list at the end of this document for possible conflicts. There are two ways to remove this error.
1.Embed names of fields and files in double quotes.
2.Replace problem field names in the *.TAG files with another name.

· No field names found - missing *.TAG file.
The driver will replace missing field names with a generic name (FIELD_8) when the name is missing so that the driver will still function. You should ensure that the .TAG files are located in the same directory as the data (.DAT) files.

· Field name longer than 15 characters.
Only 15 characters are allowed in DataFlex field names. If a field name is longer than 15 characters, it will be replaced by a generic name (FIELD_8).

· Wrong type of quote characters used .
Single quotes (') are used around data values of a non-numeric type. Double quotes (") are used around file and field names.

· Only 101 records shown in MS Access.
When a datafile is called up in a table, MS Access will only display the first 101 records. To see all records in the datafile, select a column that is an indexed field, and use the sort a-z icon.

There may be other syntax related errors we are not yet aware of. Syntax errors are always an SQL related problem, not a problem with the DataFlex file system. If you manipulate files directly via SQL, you may want to purchase a book on SQL to use with this product. This manual does not provide adequate reference to SQL syntax.

Multi-User

If you are unable to open a DataFlex file in the Single CPU version of FLEX/ODBC, it may be because the driver opens files in "exclusive" mode for this license. If you are running on a network, you will need the Multi-CPU version of the product to open shared files on a network.

Tracing

A tracing mode has been included in the product. It allows you to trace all ODBC calls made to the driver for debugging purposes. A trace log may be required by FLEXTOOLS if your application returns an unexpected error.

To trace operations, enter an ASCII filename to the driver setup screen under the ODBC icon in the control panel. A name such as:

C:cdataflexcdftrace.log

Tracing in this example will be sent to an ASCII file called c:cdataflexcdftrace.log. The trace includes all ODBC calls made and DataFlex related errors returned by the driver. If you cannot see the problem, e-mail it to us for review.



(c) FLEXquarters