| **Navigation:**  ISAM File Drivers > Btrieve Database Driver >====== Btrieve Database Driver ====== | [[basic supported commands and attributes.htm|{{btn_prev_n.gif|Previous page}}]][[coming future.htm|{{btn_home_n.gif|Return to chapter overview}}]][[btrieve driver strings.htm|{{btn_next_n.gif|Next page}}]] | | || [[database drivers.htm|Database Drivers]] [[choosing the right database driver.htm|Choosing the Right Database Driver]] [[common database driver features.htm|Common Database Driver Features]] [[driver strings.htm|Driver Strings]] [[btrieve database driver.htm#bqslprp|Btrieve:Specifications]] [[btrieve database driver.htm#r1ntdp|Btrieve:File Specifications/Maximums]] [[btrieve driver strings.htm|Btrieve:Driver Strings]] [[btrieve driver strings.htm#abm1f5f|Btrieve:Driver Properties]] [[btrieve supported commands and attributes.htm|Btrieve:Supported Commands and Attributes]] [[btrieve other.htm|Btrieve:Other]] **Btrieve:Specifications** This file driver reads and writes Btrieve files using low-level direct access. Under Clarion, the Btrieve file driver is implemented by using .DLLs and an .EXE supplied by Pervasive Software (formerly Btrieve Technologies, Inc.). For an application to use a Btrieve file driver, the following files must accompany the executable: You must purchase a 32-bit Btrieve engine from Pervasive Software. LICENSE WARNING: A registered Clarion owner cannot redistribute the above files outside of his/her organization without a license from Pervasive Software. | **Files:** | **ClaBTRL.LIB** | Windows Static Link Library | | | **ClaBTR.LIB** | Windows Export Library | | | **ClaBTR.DLL** | Windows Dynamic Link Library | **Btrieve:Data Types** | __**Clarion data type**__ | __**Btrieve data type**__ | | **BYTE** | **STRING (1 byte)** | | **SHORT** | **INTEGER (2 bytes)** | | **LONG** | **INTEGER (4 bytes)** | | **SREAL** | **FLOAT (4 bytes)** | | **REAL** | **FLOAT (8 bytes)** | | **BFLOAT4** | **BFLOAT (4 bytes)** | | **BFLOAT8** | **BFLOAT (8 bytes)** | | **PDECIMAL** | **DECIMAL** | | **STRING** | **STRING** | | **CSTRING** | **ZSTRING** | | **PSTRING** | **LSTRING** | | **DATE** | **DATE** | | **TIME** | **TIME** | | **USHORT** | **UNSIGNED BINARY (2 bytes)** | | **ULONG** | **UNSIGNED BINARY (4 bytes)** | | **MEMO** | **STRING,LVAR or NOTE****(see [[btrieve driver strings.htm#btrievememo|/MEMO]] below)** | | **BYTE,NAME('LOGICAL')** | **LOGICAL*** | | **USHORT,NAME('LOGICAL')** | **LOGICAL*** | | **PDECIMAL,NAME('MONEY')** | **MONEY*** | | **STRING(@N0n-),NAME('STS')** | **SIGNED TRAILING SEPARATE*** | | **DECIMAL*** | | //Notes//: *****You can store Clarion DECIMAL types in a Btrieve file. However, you cannot build a key or index using the field. This is provided for backward compatibility with older Clarion programs which used the Btrieve LEM. If you need standard Btrieve decimal data that is compatible with any other Btrieve compliant program, you should use the PDECIMAL data type and not the DECIMAL data type. *****If you want to create a file with LOGICAL or MONEY field types, you must specify LOGICAL or MONEY in the field's NAME attribute. If you are accessing an existing file, the NAME attribute is not required. *****LOGICAL may be declared as a BYTE or USHORT, depending on whether it is a one or two byte LOGICAL: **    LogicalField1  BYTE    !One byte LOGICAL** **    LogicalField2  USHORT  !Two byte LOGICAL** *****MONEY may be declared as a PDECIMAL(x,2), where //x //is the total number of digits to be stored: **MoneyField PDECIMAL(7,2),NAME('MONEY') !Store up to 99999.99** *****Btrieve NUMERIC fields are not fully supported by the driver. Btrieve NUMERIC is stored as a string with the last character holding a digit and an implied sign. The possible values for this last character are: **            1 2 3 4 5 6 7 8 9 0** **Positive:   A B C D E F G H I {** **Negative:   J K L M N O P Q R }** *****To access a NUMERIC field you must define a STRING(@N0x), where x is one less than the digits in the NUMERIC, and a STRING(1) to hold the sign indicator. The Btrieve driver does not maintain this sign field, the application must be written to directly handle it. *****For example to access a NUMERIC(7) you would have: **NumericGroup GROUP         !Store -999999 to 999999** **Number        STRING(@N06) !Numbers** **Sign          STRING(1)    !Sign indicator** **             END** **Btrieve:File Specifications/Maximums** {{notebox.jpg|NoteBox.jpg}} The specifications below document Version 6.15. Your specific limits are dependent on what version of Btrieve you are using, and are not dependent on the Btrieve driver. Refer to your Btrieve documentation for your specific limitations. **File Size :            4,000,000,000 bytes** **Records per File :     Limited by the size of the file** **Record Size** ** Client-based :        65,535 bytes variable length** ** Server based :        57,000 bytes variable length** **Field Size :           65,520 bytes** **Fields per Record:     65,520** **Keys/Indexes per File: 24 with NLM5** **                       256 with NLM6.** **Client Btrieve v6.15 ** __**Page Size**__**   **__**Max Key Segments**__ **512               8** **1,024             23** **1,536             24** **2,048             54** **4,096             119** **This is the total number of components. If you have a multicomponent key built from three fields, this counts as three indexes when counting the number of allowed indexes.** **Key Size :            255 bytes** **Memo fields per File: System memory dependent** **Memo field size :     65,520 bytes** **Open Files :          Operating system dependent** {{notebox.jpg|NoteBox.jpg}} **The Btrieve driver supports data only and key only files.**