Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ACT and ODBC dBase driver

Status
Not open for further replies.

MikeT

IS-IT--Management
Feb 1, 2001
376
0
0
US
Hello
I can connect to an ACT 6.0 database via the following adodb connection string:

Driver={Microsoft dBASE Driver (*.dbf)};DriverID=277;Dbq=C:\test;

However if I query all records, I don't get as many records returned as the ACT program shows:

Act shows I have 639 contacts in a database, but if I do "SELECT * FROM test.dbf", only 527 records get returned.

To top it all off, some of those 527 are records that have been deleted from Act!

Do you have any idea why this is, and what I could do to fix it?
 
I'm not familiar with ACT nor connecting to it, but since I don't see any other help appearing......

If you're accessing a .dbf with dBase (sounds like you are)and getting an unexpectedly low number of records returned by any command, my first inclination is think about records in the database that are marked as deleted.

In dBase, there is an environment variable which determines whether "deleted" records are included in operations performed by various commands. It's status is set with the SET DELETED [ON/OFF] command. If records exist that are marked for deletion and SET DELETED ON has been issued, then those records get excluded, even though they still exist in the database.

So, from dBase I would first check the status of DELETED at the point the query is being executed. If it's set ON, then either PACK the database to eliminate the records if they are unnecessary, or issue SET DELETED OFF to include the records in the query.

The status of DELETED wouldn't seem to explain both of the anomolies you're experiencing,but might help to eliminate one so you can troubleshoot the other.

hth
Dennis [glasses]
 
My past experience with ACT was that it was run by a customized DB engine and wasn't compliant with the standard .dbf ODBC driver. I tried opening the database with dBase IV and Access.

Try calling ACT and find out if their DB is compliant now or not. ACT is now selling a query tool, Stonefield query. They probably won't give you any help except to sell you the software (Imagine that).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top