In order to use the ACE wrappers, you will need to download the Advantage Client Engine DLLs from: http://sqlexpress.net/download Once downloaded, unzip all files in the same directory where your sample executables are located. You may also wish to download the ACE SDK help file from the Advantage Database solutions website: http://devzone.advantagedatabase.com
Although not a true DBE like the Alaska Software ADSDBE, this library performs its magic by using the very powerful Xbase++ preprocessor to translate certain Xbase++ commands and functions to specific ACE Wrapper functions. All of these preprocessor macros are defined in ACE_UDF.CH. You may think that since this library is written entirely in Xbase++, that it's performance would not be as good when compared to the ADSDBE which is written in C++. However you will be happy to know that this is not the case, in reality the ACE Wrappers are just as fast and in some cases even faster, than Alaska's ADSDBE. No additional DBE's are needed when using the ACE Wrappers, but to make it all work you will need to do the following:
XPP TEST.PRG /P
SQL Replication:
One of the most exciting features of the ACE Wrappers is seamless SQL replication of data using SQLExpress. With
just one simple function call at the start of your program, The ACE Wrappers will automatically replicate DBF/ADT
changes into an external SQL/ODBC data source. Data replication can be used to present a real-time, external view
of your DBF/ADT data for reporting and querying purposes. To see how this magic feat is accomplished, search
ACE.PRG for the keyword "_ENABLE_SQL_REPLICATION". To start using SQL replication, do the following:
PROCEDURE DbeSys()
// set the default table type to be ADS_CDX
AceSetTableType("DBFCDX")
// define ODBC connection to replicated database:
AceSQLReplicateConnection('DRIVER=SQL Server;SERVER=DWS-01;UID=Xpp;PWD=Clipper;DATABASE=DataMart2')
// define ADT or DBF tables that will be replicated:
AceSQLReplicate('CUSTOMER')
AceSQLReplicate('SUPPLIER')
AceSQLReplicate('ORDERS')
RETURN
#define _TABLES_TO_REPLICATE {'CUSTOMER', 'SUPPLIER', 'ORDERS'}