Defining a Schema
Last updated Dec 22nd, 2019 | Page history | Improve this page | Report an issue
Support the team building MODX with a monthly donation.
The budget raised through OpenCollective is transparent, including payouts, and any contributor can apply to be paid for their work on MODX.
$292 per month—let's make that $500!Learn more
What is a Schema?¶
xPDO generates its map and class files, which power the database relationships, from XML schema files. An XML schema is based on a package that defines the name of the schema and allows xPDO to load the schema with its classes dynamically at any time using xPDO.addPackage.
Please note that the default schema version changed in xPDO 2.0.0-rc3 to version 1.1. If you created your model in releases before 2.0.0-rc3, and you want to use the new index elements for describing your indexes, you can migrate to the new schema format by using the upgrade tool included with xPDO. See Upgrading Models to Schema Version 1.1 for more information.