podoc:database_schemas
Schema documentation
These pages document the database schema of Photo Organizer.
The specific pages for the database elements (tables, views, sequences, indexes and functions) will contain the history of the database all the way back to the 2.05 release of Photo Organizer.
Status
- Databases schema is up to date with the current 2.33c release.
To Do
- Verify final schema with schema as reported by SQL dump of 2.34.
- A few cross references between tables, views, sequences, indexes and functions may be missing.
- Follow up on print_id_sequence and export_id_sequence as the documentation on these is probably wrong.
- Follow up on documentation of functions. There are some tentative descriptions that need verifying.
- For all tables, describe their use in the source code. What are the procedures for updating and using tables?
- All views need documentation on what they do and what their purpose is.
- Create a coherent picture of how photos are handled. Make a link between database and the physical reality.
Retrieving the current schema of your PO installation
To get the current database schema out of PostgreSQL you can use pg_dump:
$ pg_dump --schema po_db > po.schema
A dump of po-2.33c can be found here.
Another way to inspect your PO database is by using pgAccess. → Not available for current versions of PostgreSQL it seems.
Tables
bulk_update_ruleremoved in 2.32currencyremoved in 2.34dcraw_optionsremoved in 2.34imagemagick_composite_optionsremoved in 2.34imagemagick_optionsremoved in 2.34photo_formatremoved in 2.19photo_itemremoved in 2.34photo_spoolerremoved in 2.34preferencesremoved in 2.34printer_spoolerremoved in 2.15shop_categoryremoved in 2.34shop_itemremoved in 2.34shop_item_generator_ruleremoved in 2.34shop_orderremoved in 2.34shop_transactionremoved in 2.34shop_transaction_statusremoved in 2.34submissionremoved in 2.34submission_statusremoved in 2.34system_preferencesremoved in 2.34
Strike-through Text
Views
view_shop_item_generator_ruleremoved in 2.34view_submissionremoved in 2.34
Functions
is_photo_for_saleremoved in 2.34
Sequences
bulk_update_rule_id_sequenceremoved in 2.32bulk_upload_id_sequenceremoved in 2.31currency_id_sequenceremoved in 2.34dcraw_options_id_sequenceremoved in 2.34export_id_sequenceremoved in 2.31imagemagick_composite_options_id_sequenceremoved in 2.34imagemagick_options_id_sequenceremoved in 2.34photo_format_id_sequenceremoved in 2.19photo_item_id_sequenceremoved in 2.34photo_spooler_id_sequenceremoved in 2.34preferences_id_sequenceremoved in 2.34printer_spooler_id_sequenceremoved in 2.15shop_category_id_sequenceremoved in 2.34shop_item_generator_rule_id_sequenceremoved in 2.34shop_order_id_sequenceremoved in 2.34shop_transaction_id_sequenceremoved in 2.34shop_transaction_status_id_sequenceremoved in 2.34
Indexes
album_content_id_idxremoved in 2.34album_id_idxremoved in 2.34folder_id_idxremoved in 2.34photo_id_idxremoved in 2.34users_idxremoved in 2.34
podoc/database_schemas.txt · Last modified: 2007/10/19 20:50 by Luud