[Lazarus] PostgreSQL database connection error

peng pengtu321 at gmail.com
Wed May 28 23:04:12 CEST 2008


Thank you, Michael, in accordance with your recommendations, has been
successfully connected! However, some new problems, form In Chinese
characters appear garbled. Details are as follows:

1, Lazarus new form, from 'sqldb' tab, add the three essential components,
set up a number of attributes.
2, from 'Data Access' tab, add a component: TDataSource, set attributes
DataSet.
3, from the 'Data Controls' tab, add a component: TDBGrid, set attributes
DataSource.

In this way, the editorial in the state of Lazarus, I can see TDBGird change
from a blank  into the full data. However, in the form of Chinese data
garbled, even in the running after this. In an earlier time, I have tried to
connect SQLite database, edit state is garbled, but in normal operation
after RUN it. These two databases are UTF8 encoding, it appears to be a big
problem. I am very eager to see the Chinese in the data.

UTF8 or ANSI, give me a recommendation? Thank you!

2008/5/29 Michael Van Canneyt <michael at freepascal.org>:

> To use SQLDB, you need always 3 components:
>
> 1. A TSQLConnection component.
>   This controls the connection to the database.
>
> 2. A TSQLTransaction component.
>   This controls the transaction in which a query is executed.
>   It is connected to the TSQLConnection.
>
> 3. A TSQLQuery component.
>   This executes queries.
>   It is connected to the TSQLConnection component (the database)
>   and the TSQLTransaction (the transaction context).


> Michael.
>

-- 
我的'开源办公室':
http://pengtu.net/ooo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20080529/58754bba/attachment-0007.html>


More information about the Lazarus mailing list