Difference between revisions of "Lazarus DB Faq/es"

From Lazarus wiki
Jump to navigationJump to search
Line 14: Line 14:
Mira [[Install Packages/es|aquí]] para ayuda sobre cómo instalar paquetes.
Mira [[Install Packages/es|aquí]] para ayuda sobre cómo instalar paquetes.
=== Are there other components? ===
=== ¿Existen otros componentes? ===
   Yes. The [http://zeoslib.sourceforge.net/index.php ZEOS components] have been ported to Lazarus as well.
   . Los [http://zeoslib.sourceforge.net/index.php componentes ZEOS] ha sido convertidos para se utilizados en Lazarus.
<br>You have to download ZEOSDBO_Rework from [http://sourceforge.net/cvs/?group_id=35994 ZEOS cvs].
<br>See also this tutorial for [[Zeos_tutorial|Zeos]].
&nbsp;&nbsp;&nbsp;Hay que descargar el ''ZEOSDBO_Rework'' de [http://sourceforge.net/cvs/?group_id=35994 ZEOS cvs].
<br>[http://pdo.sourceforge.net Pascal Data Objects] works equally with Delphi and FPC 2.0 (MySQL and Firebird)
&nbsp;&nbsp;&nbsp;Mira también el tutorial de [[Zeos_tutorial|Zeos]].
&nbsp;&nbsp;&nbsp;[http://pdo.sourceforge.net Pascal Data Objects] trabaja también con  Delphi y FPC 2.0 (para MySQL y Firebird)
== IB / FB ==
== IB / FB ==

Revision as of 12:05, 8 July 2008

Deutsch (de) English (en) español (es) français (fr) italiano (it) 日本語 (ja) português (pt) русский (ru) slovenčina (sk) 中文(中国大陆)‎ (zh_CN)

Descripción general

   Este FAQ se dirige a la programación Lazarus con bases de datos.

Dónde encontrar más FAQ?

   Buscar en el sitio oficial www.lazarus.freepascal.org. Esta no es más que otro FAQ. Aquí puedes encontrar una página que empezó siendo una copia de la FAQ de www.lazarus.freepascal.org .

¿Dónde encontrar componentes para Bases de Datos?

   Ahora los componentes SQLdb forman parte del paquete Lazarus, sólo es necesario instalarlo. Si miras en [$LazarusDir]/components verás el directorio SQLdb. Instala el paquete (sqldblaz.lpk) y podrás conectar a servidores MySQL, Interbase / Firebird and Postgres. Mira aquí para ayuda sobre cómo instalar paquetes.

¿Existen otros componentes?

   Sí. Los componentes ZEOS ha sido convertidos para se utilizados en Lazarus.

   Hay que descargar el ZEOSDBO_Rework de ZEOS cvs.

   Mira también el tutorial de Zeos.

   Pascal Data Objects trabaja también con Delphi y FPC 2.0 (para MySQL y Firebird)


How do I connect from Linux to a Windows server

Entering the correct path to a database on a Windows server from a Linux client is not very clear.

Say you have installed firebird in F:\Program Files\firebird\. The employee.fdb example database will then be installed in the directory F:\Program Files\firebird\examples\ . The IP-adress of your computer is

Then entering the following databasename\Program Files\firebird\examples\employee.fdb

in your IBConnection will connect to the required database.

Note that you don't have to enter a value for the hostname property!


Which version of mySQL is supported?

Currently MySQL 4.0, MySQL 4.1 and MySQL 5.0 are supported by de SQLdb components. Make sure you are using the correct connection component for your client library version. So if you have the client libraries installed for MySQL 4.1 then you have to use TMySQL41Connection component, even if the server is running version 4.0 or 5.0.

Pascal Data Objects

There is now an alternative. The functions introduced with MySQL 4.1 and 5.0 like prepared statements, binding, and stored procedures are supported by database API called Pascal Data Objects, which is inspired by PHP Data Objects. All the code and documentation necessary to use this new API is available on sourceforge:


Jan 30, 2007: PDO has added drivers for Firebird 1.5 and 2.0


You can connect to PostgreSQL db by TPQConnection component. This component uses the PostgreSQL's libpq connection library[1], so you can easily connect almost every PostgreSQL db, but the component doesn't support the following connection options:

  • Port
  • ClientEncoding

Maybe there are other unsupported connection parameters.