Difference between revisions of "Lazarus DB Faq/fr"

From Free Pascal wiki
Jump to navigationJump to search
(New page: {{Lazarus Documentation}} ==Lazarus and Pascal Tutorials== *Overview of Free Pascal and Lazarus - A brief discussion of kinds of things you can develop with these general-purpose tool...)
 
 
(21 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{Lazarus Documentation}}
+
{{Lazarus DB Faq}}
 +
{{Infobox databases/fr}}
  
==Lazarus and Pascal Tutorials==
+
== General ==
*[[Overview of Free Pascal and Lazarus]] - A brief discussion of kinds of things you can develop with these general-purpose tools.
 
*[[Lazarus Tutorial]] - A tutorial for beginners and a detailed description of the Lazarus IDE.
 
*[[Lazarus IDE Tools]] - An intermediate level tutorial about code completion and other IDE tools.
 
*[[Lazarus Database Tutorial]] - An introduction to using Lazarus with databases.
 
*[[Developing with Graphics]] - Some basic examples on graphic programming.
 
*[[Pascal Tutorial]] - [http://www.taoyue.com/ Tao Yue's] [http://www.taoyue.com/tutorials/pascal/ Pascal Tutorial]  (reposted with permission).
 
*[[TXMLPropStorage]] - Using TXMLPropStorage to save user preferences.
 
*[[Executing External Programs]] - A short tutorial showing how to run external programs from inside your program.
 
*[[Hardware Access]] - How to access hardware devices, such as ISA cards, PCI cards, parallel and serial ports and USB devices.
 
*[[Networking]] - Tutorials about XML, TCP/IP protocol, creating secure network programs, WebServices, etc.
 
*[[Multithreaded Application Tutorial]] - How to write multithreaded applications using Free Pascal and Lazarus
 
*[[Streaming components]] - How to write components to streams and read/create components from streams
 
*[[OpenGL Tutorial]] - How to use GLUT in Lazarus
 
*[[Creating bindings for C libraries]] - How to convert C header files (.h) to pascal units
 
*[[Lazarus/FPC Libraries]] - How to create dynamic libraries (.so, .dll, .dynlib) and how to use them
 
  
==The Lazarus User Guides==
+
Cette FAQ porte son attention sur la programmation de bases de données avec Lazarus.
*[[Lazarus Faq]] - General information about Lazarus and specifics for Linux and Windows users.
 
*[[Lazarus DB Faq]] - FAQ on database issues in Lazarus.
 
*[[Code Examples]] - Example working code for Lazarus.
 
*[[Feature_Ideas|Wishlist/Wanted Features]] - Features that you would like to see in Lazarus
 
*[[How do I create a bug report]] - You think you found a bug in Lazarus, how can you report it?
 
===Installation===
 
*[[Installing Lazarus]] - An installation guide (please add to it!)
 
*[[Getting Lazarus]] - Instructions on how to download a released or SVN version of Lazarus
 
*[[OS X Programming Tips]] - Lazarus installation, useful tools, Unix commands, and more...
 
===IDE===
 
*[[IDE tricks]] - Tips, tricks and hidden features
 
*[[Lazarus IDE]] - The IDE windows
 
*[[Lazarus Packages]] - A guide for creating a package under Lazarus
 
*[[Install Packages]] - A small guide to install packages
 
*[[Extending the IDE]] - How to add functionality to the Lazarus IDE
 
*[[Adding Kylix Help]] - How to use the Borland Help files within the IDE editor.
 
  
===LCL===
+
=== Où puis-je trouver plus de FAQ? ===
*[[doc:lcl/|LCL documentation]] - On line help for LCL (work in progress).
 
*[[Main Loop Hooks]] - How to handle multiple event sources
 
*[[Asynchronous Calls]] - How to queue methods for later execution
 
*[[File size and smartlinking]] - How to smartlink applications and create smaller executables.
 
*[[Accessing the Interfaces directly]] - Example how to access the LCL widgetsets
 
*[[Add Help to Your Application]] - How to create a Online Help for your application
 
*[[Anchor Sides]] - Description of Anchor Sides Feature
 
*[[LCL Tips]] - Tips and tricks
 
*[[LCL Defines]] - Choosing the right options to recompile LCL
 
  
===Developing===
+
Voir le site officiel www.lazarus.freepascal.org. Il y a une autre FAQ aussi. [[Lazarus Faq/fr|Ici]] vous trouvez une page qui à été au moins au début une copie de la FAQ de www.lazarus.freepascal.org .
*[[The Power of Proper Planning and Practices]] - common-sense programming best practices for the Free Pascal and Lazarus developer
 
*[[Multiplatform Programming Guide]] - How to develop cross-platform applications and how to port from one platform to another
 
*[[Using Pascal Libraries with .NET and Mono]] - yes, you can use your Free Pascal code with .NET and Mono
 
*[[Deploying Your Application]] - How to create an installer for your application
 
*[[Cross compiling]] - Creating executables of one platform, on another.
 
*[[Remote Debugging]] - How to debug your Lazarus application from another machine.
 
===Tools===
 
*[[Lazarus Documentation Editor]] - Using "lazde" to create documentation
 
*[[LazDoc]] - An integrated editor for documentation files
 
*[[lazbuild]] - Compiling projects and packages without the IDE
 
  
===Coming from Delphi===
+
=== Où puis-je trouver plus d'information ? ===
*[[Lazarus Components]] - Comparison between Lazarus and Turbo Delphi components
+
Sur les bases de données :
*[[Lazarus For Delphi Users]] - For Delphi users who are getting started with Lazarus
+
* Voir [[Databases/fr|Bases de données]] et les articles sur l'emploi des bases de données et de SQLQuery.
*[[Code Conversion Guide]] - How to convert existing code and components from Delphi and Kylix
 
  
==The Lazarus Developer Guides==
+
=== Où puis-je trouver des composant de base de données ? ===
*[[How To Help Developing Lazarus]] - A guide to help newbies start improving Lazarus
 
*[[Version Numbering]] -  Explanation of the different version numbers of Lazarus
 
*[[Creating A Patch| Creating a Patch]] - A guide to making a patch with changes made to Lazarus
 
*[[Creating a Backtrace with GDB]] - A guide to making a backtrace to help you debug a program
 
*[[Nomenclature]] - Guide to choose a name for a new method or property
 
*[[DesignGuidelines|Design Guide Lines]] - A guide about how to procede when changing Lazarus Source Code.
 
*[[GUI design]] - Notes on guidelines when designing the lazarus GUI
 
*[[Roadmap]] - An idea of the current status of the various parts of Lazarus
 
*[[Road To 1.0]] - What needs to be done for Lazarus 1.0
 
*[[Moderating the bug tracker]] - Guidelines for lazarus developers and moderators for using the [http://www.freepascal.org/mantis/ bug tracker].
 
*[[Codetools]] - How the codetools are integrated into the IDE
 
*[[Creating IDE Help]] - How to extend the IDE documentation
 
*[[Unit not found - How to find units]] - How to setup the IDE and source files
 
*[[Bounties]] - Need a particular new feature soon? Set a price here.
 
  
===LCL - Lazarus component library===
+
Pour le moment les composants SQLdb font partie components de la suite Lazarus, vous devez seulement les installer. Si vous cherchez dans le répertoire [$LazarusDir]/components vous vers un sous répertoire SQLdb. Installez le paquet sqldblaz.lpk et vous serez capable de vous connecter aux serveurs MySQL, Interbase / Firebird et Postgres.
*[[LCL Messages]] - Guide related to LCL Messages
+
Regardez [[Install Packages|Ici]] pour l'aide sur l'installation des paquets.
*[[LCL Internals]] - Some info about the inner workings of the LCL
 
*[[LCL Key Handling]] - Help! A key press, what now?
 
*[[LCL Unicode Support]] - Road to Unicode enabled Lazarus
 
*[[LCL Documentation Roadmap]] - Which units have to be documented
 
  
===Interfaces===
+
=== Bases de données prises en charge ===
*[[GTK2 Interface]] - The gtk2 for Unixes, Mac OS X, Windows
+
* Voir [[Lazarus Database Overview/fr|Vue d'ensemble des bases de données avec Lazarus]] pour une liste des bases de données prises en charge par SQLDB.
*[[Carbon Interface]] - The Carbon Interface for Mac OS X
 
*[[Qt Interface]] - The Qt 4 Interface for Unixes, Mac OS X and linux-based PDAs
 
*[[Windows CE Interface]] - For Pocket PC and Smartphones
 
*[[fpGUI Interface]] - A widgetset completely written in Object Pascal
 
  
===Translations===
+
=== Problèmes connus ===
* [[Getting translation strings right]] A few notes for programmers on how to create and use translateable strings in your application. Quickly discusses general things about creating strings, offers a few hints on implementation issues and points out some things to consider when using English as base language in particular.
+
* Voir [[fcl-db#Known%20issues/shortcomings]]
* '''Localization Notes:'''
 
:* [[German localization notes|German]] - Notes and guidelines for translating the Lazarus IDE to German, including a small dictionary to look up often used translations.
 
:* [[Portuguese-Brazilian Localization Notes|Portuguese-Brazilian]] - Small dictionary containing common translations of terms used in the Lazarus IDE for the Portuguese-Brazilian translation.
 
<!-- *[[TO-DO]] Remaining Tasks -->
 
* [[Help:Add language bar | Add language bar]] explains how you can add a list of translations to the top of a wiki page.
 
  
==Additional Components Documentation==
+
=== Y a t'il d'autres composants ? ===
*[[Pascal Script]] and [[Pascal Script Examples]] - How to use the pascal script components in Lazarus
 
*[[OpenGL]] - How to use OpenGL in Lazarus
 
  
==Free Pascal Compiler Documentation==
+
Oui. Les [http://zeoslib.sourceforge.net/index.php composants ZEOS] ont aussi traduits vers Lazarus.
In addition to [http://lazarus-ccr.sourceforge.net/fpcdoc/ this site], the latest version of the documentation can also be found online and in a variety of downloadable formats on the main [http://www.freepascal.org/docs.html Free Pascal Compiler site].
+
<br>Vous devez télécharger ZEOSDBO_Rework à partir du [http://sourceforge.net/cvs/?group_id=35994 cvs ZEOS].
There is now also a WiKi site for FreePascal [http://www.freepascal.org/wiki/index.php/Main_Page] very similar in style to this one, to allow developers to submit documentation in addition to the official FPC documents below.
+
<br>Voir aussi ce tutoriel pour [[Zeos_tutorial/fr|Zeos]].
 +
<br>[http://pdo.sourceforge.net Pascal Data Objects] marche également avec Delphi et FPC 2.0 (MySQL et Firebird)
  
*[http://lazarus-ccr.sourceforge.net/fpcdoc/user/user.html User's guide]
+
=== Documentation Lazarus et FPC ===
*[http://lazarus-ccr.sourceforge.net/fpcdoc/prog/prog.html Programmer's guide]
+
Les contrôle visuels de Lazarus s'appuient sur le code bases de donnée de FPC. Veuillez consulter la [http://www.freepascal.org/docs-html/fcl/sqldb/index.html documentation SQLDB] pour plus d'information.
*[http://lazarus-ccr.sourceforge.net/fpcdoc/ref/ref.html Reference guide for the system unit, and supported Pascal constructs]
 
*[http://lazarus-ccr.sourceforge.net/fpcdoc/rtl/index.html Run-Time Library reference manual]
 
*[http://lazarus-ccr.sourceforge.net/fpcdoc/fcl/index.html Free Component Library reference manual]
 
*[http://lazarus-ccr.sourceforge.net/fpcdoc/fpdoc/fpdoc.html Free Pascal documentation tool manual]
 
*[[Build messages]]
 
  
==Lazarus related blogs==
+
Information d'arrière plan sur SQLDB: [[SqlDBHowto/fr|SqlDBHowto]]
*[[Adventures of a Newbie]] - A blog of a newbie getting started with some tutorial information in a running log.
+
 
*[http://lazarusroad.blogspot.com/ On the road with Lazarus/Freepascal] - A blog dedicated to register my experiences while programming with Lazarus and Freepascal (by Luiz Américo)
+
Plus d'info sur TSQLQuery: [[Working With TSQLQuery/fr|Travailler avec TSQLQuery]]
*[http://port2laz.blogspot.com/ Porting to Lazarus] - This blog describes the porting of a medium-sized application (~100 kloc) from D7 with CLX to Lazarus (by Alexsander da Rosa)
+
 
*[http://living-lazarus.blogspot.com/ Living Lazarus] - One mans exploration into the possibilities of an open source RAD (by [[User:Wibblytim|Wibblytim]]).
+
=== Documentation Lazarus ===
*[http://beeography.wordpress.com/tag/object-pascal/ Bee.ography] just (another) Bee’s buzz!
+
* De l'information sur l'interaction entre les divers composants FPC et Lazarus : [[SQLdb Programming Reference/fr|Référence de programmation SQLdb]].
 +
 
 +
== IB / FB ==
 +
 
 +
=== Comment se connecter à partir de Linux vers un serveur Windows ===
 +
 
 +
Donner le chemin correct vers une base de donnée sur un serveur Windows server depuis un client Linux n'est pas très clair.
 +
 
 +
Supposons que nous ayons installé firebird dans le répertoire F:\Program Files\firebird\. La base de donnée en exemple employee.fdb sera alors installée dans le répertoire F:\Program Files\firebird\examples\ . L'adresse IP de votre ordinateur est 192.168.2.100.
 +
 
 +
Alors entrer le nom de base de donnée suivant 
 +
192.168.2.100:F:\Program Files\firebird\examples\employee.fdb
 +
dans notre IBConnection nous connectera à la base de donnée requise.
 +
 
 +
Noter que vous n'avez pas à entrer une valeur pour la propriété hostname!
 +
 
 +
== MySQL ==
 +
 
 +
=== Quelle version de mySQL est supportée ? ===
 +
 
 +
Actuellement MySQL 4.0, MySQL 4.1 et MySQL 5.0 sont supportés par les composants SQLdb. Soyez sur que vous êtes en train d'utiliser le bon raccordement de composant pour votre version de librairie cliente. Ainsi si vous avez les librairies clientes installées pour MySQL 4.1 alors vous devez utiliser le composant TMySQL41Connection, même si le serveur execute les version 4.0 ou 5.0.
 +
 
 +
==== Pascal Data Objects  ====
 +
Il y a maintenant une alternative.  Les fonctions introduites avec MySQL 4.1 et 5.0 tel que les instructions préparées , les procédures de liaison et de stockage sont supportées par une database API appelée Pascal Data Objects, qui  s'inspire des PHP Data Objects.  Tout le code et la documentation nécessaire pour utiliser cette nouvelle API est disponible sur sourceforge:
 +
 
 +
http://pdo.sourceforge.net
 +
 
 +
Jan 30, 2007: PDO a ajouté les drivers pour Firebird 1.5 et 2.0
 +
 
 +
== PostgreSQL ==
 +
 
 +
Vous pouvez vous connecter à la db PostgreSQL par l'intermédiaire du composant TPQConnection. Ce composant utilise la connection à la librairie libpq de PostgreSQL [http://www.postgresql.org/docs/8.0/interactive/libpq.html], aussi vous pouvez aisément connecter la plupart des db PostgreSQL, mais le composant ne supporte pas les options de connection suivantes:
 +
* Port
 +
* ClientEncoding
 +
Peut être qu'il y a d'autres paramètres de connection non supportés.

Latest revision as of 07:39, 29 June 2017

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

Portail de la base de données

Références:

Tutoriels/articles pratiques :

Bases de données

Advantage - MySQL - MSSQL - Postgres - Interbase - Firebird - Oracle - ODBC - Paradox - SQLite - dBASE - MS Access - Zeos

General

Cette FAQ porte son attention sur la programmation de bases de données avec Lazarus.

Où puis-je trouver plus de FAQ?

Voir le site officiel www.lazarus.freepascal.org. Il y a une autre FAQ aussi. Ici vous trouvez une page qui à été au moins au début une copie de la FAQ de www.lazarus.freepascal.org .

Où puis-je trouver plus d'information ?

Sur les bases de données :

  • Voir Bases de données et les articles sur l'emploi des bases de données et de SQLQuery.

Où puis-je trouver des composant de base de données ?

Pour le moment les composants SQLdb font partie components de la suite Lazarus, vous devez seulement les installer. Si vous cherchez dans le répertoire [$LazarusDir]/components vous vers un sous répertoire SQLdb. Installez le paquet sqldblaz.lpk et vous serez capable de vous connecter aux serveurs MySQL, Interbase / Firebird et Postgres. Regardez Ici pour l'aide sur l'installation des paquets.

Bases de données prises en charge

Problèmes connus

Y a t'il d'autres composants ?

Oui. Les composants ZEOS ont aussi traduits vers Lazarus.
Vous devez télécharger ZEOSDBO_Rework à partir du cvs ZEOS.
Voir aussi ce tutoriel pour Zeos.
Pascal Data Objects marche également avec Delphi et FPC 2.0 (MySQL et Firebird)

Documentation Lazarus et FPC

Les contrôle visuels de Lazarus s'appuient sur le code bases de donnée de FPC. Veuillez consulter la documentation SQLDB pour plus d'information.

Information d'arrière plan sur SQLDB: SqlDBHowto

Plus d'info sur TSQLQuery: Travailler avec TSQLQuery

Documentation Lazarus

IB / FB

Comment se connecter à partir de Linux vers un serveur Windows

Donner le chemin correct vers une base de donnée sur un serveur Windows server depuis un client Linux n'est pas très clair.

Supposons que nous ayons installé firebird dans le répertoire F:\Program Files\firebird\. La base de donnée en exemple employee.fdb sera alors installée dans le répertoire F:\Program Files\firebird\examples\ . L'adresse IP de votre ordinateur est 192.168.2.100.

Alors entrer le nom de base de donnée suivant

192.168.2.100:F:\Program Files\firebird\examples\employee.fdb

dans notre IBConnection nous connectera à la base de donnée requise.

Noter que vous n'avez pas à entrer une valeur pour la propriété hostname!

MySQL

Quelle version de mySQL est supportée ?

Actuellement MySQL 4.0, MySQL 4.1 et MySQL 5.0 sont supportés par les composants SQLdb. Soyez sur que vous êtes en train d'utiliser le bon raccordement de composant pour votre version de librairie cliente. Ainsi si vous avez les librairies clientes installées pour MySQL 4.1 alors vous devez utiliser le composant TMySQL41Connection, même si le serveur execute les version 4.0 ou 5.0.

Pascal Data Objects

Il y a maintenant une alternative. Les fonctions introduites avec MySQL 4.1 et 5.0 tel que les instructions préparées , les procédures de liaison et de stockage sont supportées par une database API appelée Pascal Data Objects, qui s'inspire des PHP Data Objects. Tout le code et la documentation nécessaire pour utiliser cette nouvelle API est disponible sur sourceforge:

http://pdo.sourceforge.net

Jan 30, 2007: PDO a ajouté les drivers pour Firebird 1.5 et 2.0

PostgreSQL

Vous pouvez vous connecter à la db PostgreSQL par l'intermédiaire du composant TPQConnection. Ce composant utilise la connection à la librairie libpq de PostgreSQL [1], aussi vous pouvez aisément connecter la plupart des db PostgreSQL, mais le composant ne supporte pas les options de connection suivantes:

  • Port
  • ClientEncoding

Peut être qu'il y a d'autres paramètres de connection non supportés.