Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,059 of 9,059 pages
About the help in other languages
All help pages

Module 9: The console and persistent objects

The ninth module of the Developers course. Learners find and run commands with the console, write a command of their own, keep their extension's data in a table through eZPersistentObject, write the SQL that remains…

Download as PDF

Address: https://doc.exponential.earth/exphelp/viewer/help/trainers/developers/module-09-the-console-and-persistent-objects/README.md

On this page

Module 9: The console and persistent objects

Real extensions run jobs on the command line and keep data of their own. This module teaches the console that runs every command, a command of the learners' own with options and exit codes, a table mapped to a class with eZPersistentObject, the rules for the SQL that persistent objects cannot express, and a migration that brings a table to every installation of a site.

At a glance

CourseDevelopers
Duration4 hours 20 minutes (with two 10-minute breaks)
Lessons5
LevelBeginner to advanced

Lessons

LessonDurationWhat learners do
Lesson 9.1: The console35 minuteslist, help, namespaces, cronjob parts
Lesson 9.2: A command of your own50 minutesext:mysite_hello:latest with options, help and exit codes
Lesson 9.3: Persistent objects60 minutesA table and the class mysiteGreeting: store, fetch, count, remove
Lesson 9.4: SQL safely with eZDB45 minutesA report, escaping, a transaction with rollback, dialects
Lesson 9.5: Migrations50 minutesA table shipped as a migration: generate, check, dry run, simulate, run, roll back

Preparing this module

  • Lessons 9.3 and 9.4 use SQLite syntax for the table; development installations from exp:install are on SQLite. For a class on MySQL or PostgreSQL, prepare the CREATE TABLE for that engine in advance.
  • Learners run commands as their own user, not root.
  • Keep finished copies of latest.php, mysitegreeting.php and the scripts for learners who fall behind.

Timing plan

PartMinutes
Lesson 9.135
Lesson 9.250
Break10
Lesson 9.360
Lesson 9.445
Break10
Lesson 9.550
Total260

Become an Exponential Partner

Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.

Something wrong on this page? Report an error

Documentation license

This documentation is free documentation, licensed under the GNU Free Documentation License 1.3 or later.

Exponential Copyright © 1998-2026 Exponential Foundation and 7x