Catalog of PostgreSQL queries for finding information about a PostgreSQL database and its design problems

AND
AND
ANDQueries of this category provide information about registration of classifiers.
ANDFrom where does the query gets its information?
AND
AND

There are 6 queries.

Seq nrNameGoalTypeData sourceLast updateLicense...
1A state machine is implemented with the help of a state classifier tableFind implementations of state machines that use a state classifier table.Generalsystem catalog base tables only2023-11-26 15:39MIT License
2Do not leave out the referential constraints (based on classifiers)Find non-key and non-foreign columns of base tables with a textual column and small field size in case of which there is a table with the name that is similar to the column name. Perhaps the table is a classifier table and the column should have a foreign key constraint referencing to the table.Problem detectionINFORMATION_SCHEMA+system catalog base tables2021-03-18 11:14MIT License
3Multiple tables share the same state classifierFind cases where multiple tables share the same state classifier. For each main entity type one should create a separate state classifier table. Even if the classifier values are the same in case of two entity types for now these may become different in the future. Having a shared state classifier table usually means very simplistic state machines (states active and inactive) that could point to the gaps in analysis.Problem detectionsystem catalog base tables only2023-12-30 15:51MIT License
4One true lookup tableFind tables that contain all (or most) of the classifier values and tables that refer to these.Problem detectionsystem catalog base tables only2021-02-25 17:29MIT License
5Potentially a classifier is missing (based on field sizes)Find columns that are not covered by a primary key, unique, and foreign key constraint but have a textual type with the maximum field size 3 or less.GeneralINFORMATION_SCHEMA+system catalog base tables2021-03-10 13:07MIT License
6Potentially a classifier table is missing (based on field sizes)Find columns that are not covered by a primary key, unique, and foreign key constraint but have a textual type with the maximum field size 3 or less and where the column name does not refer to names or comments. Return only data about these columns where there is no table with a similar name. Return data only about tables that could be referenced from more than one table.Problem detectionINFORMATION_SCHEMA+system catalog base tables2021-03-18 20:08MIT License