Onsite training

Bring our trainers team onsite to train your employees.

Learn more


Doctrine

Database abstraction with PHP & Doctrine 2

Tired to write SQL queries by hand? Improve your productivity thanks to the smart and powerful Doctrine 2 library!


This training will help you to master the Doctrine 2 database abstraction or object relational mapper library.

Coming sessions


- Date Venue Price  
French Feb. 27 - Feb. 29 Paris 1490.00 € Closed
  • This session will take place from February 27, 2012 at 9:00 AM to February 29, 2012 at 5:30 PM (Europe/Paris) and it will be hosted by Hugo Hamon.

French May. 21 - May. 23 Paris 1490.00 € Register
  • This session will take place from May 21, 2012 at 9:00 AM to May 23, 2012 at 5:30 PM (Europe/Paris) and it will be hosted by Hugo Hamon.

French Aug. 20 - Aug. 22 Paris 1490.00 € Register
  • This session will take place from August 20, 2012 at 9:00 AM to August 22, 2012 at 5:30 PM (Europe/Paris) and it will be hosted by Hugo Hamon.

French Nov. 12 - Nov. 14 Paris 1490.00 € Register
  • This session will take place from November 12, 2012 at 9:00 AM to November 14, 2012 at 5:30 PM (Europe/Paris) and it will be hosted by Hugo Hamon.


Goals


During three days, you will learn how to increase your productivity thanks to Doctrine 2, the PHP ORM framework.


Program

Download the program as PDF

Interact with a relational database thanks to PHP and the PDO extension

  • Introduction to PDO (DSN, prepared statements, transactions…)
  • Establishing a MySQL or SQLite connection with PDO
  • Executing a SQL query on the database
  • Securing critical SQL statements with a transaction
  • Refactoring the business logic into model classes

Introduction to the Doctrine 2 PHP library

  • Introduction to the Doctrine2 library
  • Installing Doctrine2 from Git and PEAR
  • Discovering database abstraction pros and cons
  • Exploring the Doctrine2 architecture (Common / DBAL / ORM)

Databases abstraction with the Doctrine 2 DBAL component

  • Introduction to the database abstraction principle
  • Connectiong to a MySQL or SQLite databases
  • Selecting records from a database table
  • Inserting new records in a database table
  • Updating some database records
  • Deleting records from the database
  • Executing SQL queries in a transaction to ensure security
  • Manipulating a database schema (tables, columns, indexes…)

Object relational mapping with the Doctrine 2 ORM component

  • Discovering the object relational mapping principle
  • Designing a database schema by defining PHP classes
  • Adding relations between models (1-n, m-n, 1-1…)
  • Adding table indexes
  • Persisting business objects to the database
  • Querying a database thanks to the QueryBuilder object
  • Overloading business objects with custom methods
  • Detaching objects from their persistence manager
  • Executing batch SQL queries
  • Writing abstract SQL queries thanks to the DQL language

Migrating a database schema thanks to the Migrations component

  • Introduction to the Doctrine 2 Migrations component
  • Creating migration classes by hand
  • Generating migration classes from an existing database schema
  • Automating migration procedures from the command line interface

Session details


Reference code

DOC2C1

Price

Starts at 1490.00 € (ex. tax)

Audience

PHP developers

Duration

3 days (21 hours)

Training type

Workshop

Topics

Databases, Doctrine2, ORM

Pre-requisites

Mastering PHP 5.3 & Object Oriented Programming


For further information

+33 140 998 205

We remain at your disposal for further information.

Contact us