如何用DBExpress连接sqlite,按照网上说的,下载安装sqlite dbexpress driver后。
竟然连接不成功。到底怎么安装sqlite dbexpress driver呢,按其说明,改写dbxdrivers.ini后,还是不行。
请问:为什么这个控件的说明只让改写dbxdrivers.ini,而却没有改写dbxconnections.ini文件的说明呢。到底是怎么改写dbxconnections.ini,才能安装成功啊。急!
Installation of DbxSQLite.dll
----------------------------------------------------
1 Locate the dbxdrivers.ini on your computer.
2 Add the following lines to it:
[Installed Drivers]
SQLite=1
[SQLite]
LibraryName=C:\....\DbxSQLite.dll
GetDriverFunc=getSQLDriverSQLite
VendorLib=C:\....\sqlite.dll
RoleName=Cache=2000|TextLength=1024
3 Fire up Delphi
4 Add a TSqlConnection component
5 Set the DriverName to "SQLite"
6 Open the component editor ("Edit connection
properties")
7 Create a new connection and set the Database to a
file (If you don't have a file it will be created
upon connecting)
8 Create some ClientDataSet structure
enter your SQL and build your applications
For support mail me at:
sqlite@wobben.com
or use the
sqlite@yahoogroups.com maillist.
----------------------------------------------------
Notes
----------------------------------------------------
When having trouble always use the SQLMonitor to see
what is happening within the DbxSQLite driver.
Since SQLite is typeless and everything is stored
as text the following DataTypes are parsed and
supported:
- CHAR, VARCHAR, TEXT, GUID, BIT
Special characters are encoded using &xx; values.
Where the xx is the hexadecimal representation.
- DATE, TIME, DATETIME, TIMESTAMP
Encodings are following the rules yyyymmdd for
date and hhnnsszzz for time.
- NUMERIC, DECIMAL, DOUBLE
- BLOB, BYTES, VARBYTES
Binary to hex notation and back is performed.
- BOOLEAN, BOOL
Stored as 0 or 1.
- INTEGER, SMALLINT
Smallint is 16bit integer and Integer is a 32bit
integer.
Large text fields are not converted to blobs; this
is typical BDE behaviour to convert text datatypes
larger than 255 characters as memo blobs. You may
override this behaviour to be identical to the BDE
by setting BdeBlobText=True.