[Lazarus] SQLConnector
Andrea Mauri
andrea.mauri.75 at gmail.com
Tue Dec 2 11:35:13 CET 2008
Joost van der Sluis ha scritto:
> Op maandag 01-12-2008 om 16:48 uur [tijdzone +0100], schreef Andrea
> Mauri:
>
>> where I can find information about how to use the SQLConnector
>> component? Is it a general object that can be used to connect to
>> different database types (SQLlite, Firebird, MySQL...)?
>>
>
> That's the idea.
>
>
>> I saw the property ConnectorType (string), how can I set it? Is
>> TSQLConnector already usable?
>>
>
> You could try, but if I'm correct there are some fundamental flaws in
> it's design.
>
> If you need a generic way to connect to several types of databases, just
> use simple code like this:
>
> var AConn : TSQLConnection;
>
> begin
> case DBType of
> typeFirebird : Aconn := TSQLIBConnection.Create;
> typeMysql40 : AConn := TMysql40Conn.Create;
> etc..
>
>
Thanks a lot. I will try it.
Andrea
> Joost.
>
> _______________________________________________
> Lazarus mailing list
> Lazarus at lazarus.freepascal.org
> http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
>
>
--
Dr. Andrea Mauri, PhD
Milano Chemometrics and QSAR Research Group
Department of Environmental Sciences
University of Milano-Bicocca
P.zza della Scienza, 1
20126 Milano - Italy
Tel: ++39 02 64482801
mailto:andrea.mauri.75 at gmail.com
http://michem.disat.unimib.it/chm/
More information about the Lazarus
mailing list