Annotation Database Entity Documentation

From MediaWiki
Revision as of 22:20, 20 September 2025 by Rob (talk | contribs) (Replaced content with "== Documentation == Database entity documentation is generated automatically from the production database by the Django task, [https://gitlab.com/rskelly/msea-services/-/blob/main/services/shared/tasks/db_documentation.py db_documentation.py]. The script automatically modifies this page, replacing the text between the <!-- BEGIN GENERATED CONTENT --> and <!-- END GENERATED CONTENT --> tags. Documentation resides in the database itself, in the form of co...")
Jump to navigation Jump to search

Documentation

Database entity documentation is generated automatically from the production database by the Django task, db_documentation.py. The script automatically modifies this page, replacing the text between the <!-- BEGIN GENERATED CONTENT --> and <!-- END GENERATED CONTENT --> tags.

Documentation resides in the database itself, in the form of comments on the relations and columns. Documentations can be created by executing SQL statements in the form,

   COMMENT ON SHCEMA [schema] IS 'This is a schema comment.'
   COMMENT ON TABLE [schema].[table name] IS 'This is a table comment.'
   COMMENT ON COLUMN [schema].[table name].[column name] IS 'This is a column comment.'

Comments on MSEA's tables are managed using DDL, as described on the Database Upgrades page. Many other tables are generated by application frameworks and are not documented.

Note: this page is auto-generated from the documentation comments in the actual database. Do not edit it directly.