Seq nr | Name▲ | Goal | Type | Data source | Last update | License | ... |
---|---|---|---|---|---|---|---|
121 | Candidate keys where all columns have a static default value | Find base table primary key and unique constraints where all columns probably have a static default value. Candidate key columns (columns that belong to the primary key or to an unique constraints) shouldn't have static default values unless you are enforcing a rule that a table can have at most one row. The point of default values is that system assigns them automatically. There cannot be multiple rows with the same key value. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2023-11-12 11:33 | MIT License | |
122 | Cannot accommodate all the fractional seconds in case of table columns | The precision of a timestamp type of a column must be able to accommodate all the fractional seconds of the default value of the column. Find table columns with the type timestamp without time zone(m) or timestamp with time zone(m) that have a default value LOCALTIMESTAMP(n) or CURRENT_TIMESTAMP(n) WHERE n>m. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:30 | MIT License | |
123 | Cannot register all legal e-mail addresses | Find CHECK constraints on base table or foreign table columns that contain data about e-mail addresses and apply unnecessary restrictions to the these, rejecting potentially some legal addresses. More precisely, find CHECK constraints that prevent registration of e-mail addresses with multiple @ signs. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2021-02-25 17:29 | MIT License | |
124 | Cannot register all legal personal names | Find CHECK constraints on base table or foreign table columns that contain data about personal names and apply unnecessary restrictions to the names, rejecting potentially some legal names. Find checks that prohibit a digit or require a letter A-Z. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2021-02-25 17:29 | MIT License | |
125 | Cascading update is not needed (based on surrogate keys) | Find foreign key constraints that reference to a candidate key that is a surrogate key, i.e., its values are generated by the system by using sequence generators. Do not use ON UPDATE CASCADE, ON UPDATE SET NULL, and ON UPDATE SET DEFAULT in case of foreign keys that reference to surrogate keys. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2024-11-28 12:31 | MIT License | |
126 | Case insensitive search | Refers to the column pg_proc.prokind and thus works starting from PostgreSQL 11. Find user-defined routines and derived tables (views/materialized views) that have a subquery with case insensitive search (by using the upper or lower function or ILIKE predicate or (?i) modifier of a regular expression pattern). | General | INFORMATION_SCHEMA+system catalog base tables | 2021-10-25 16:55 | MIT License | |
127 | Case sensitive and case insensitive uniqueness of the same simple key | Find sets of columns that have both case sensitive and case insesitive unique constraints enforced based on these columns. In case of textual columns uniqueness could be checked either in case sensitive or case insensitive way. It is a contradiction to check the uniqueneness in both ways in case of the same key. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2021-02-25 17:29 | MIT License | |
128 | Chains of ON DELETE CASCADE | Find all referential paths (chains of of parent-child tables that are associated through foreign key constraints) where all foreign key constraints have ON DELETE CASCADE compensating actions. Be careful with too long chains. | General | system catalog base tables only | 2022-10-29 20:04 | MIT License | |
129 | CHAR columns have a default value that length is shorter from the character maximum length of the column | Choose a suitable data type, field size, and default value. If the default value is shorter from the character maximum length, then spaces will be added to the end of the registered value. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:30 | MIT License | |
130 | CHAR or VARCHAR columns have a default value that length is longer from the character maximum length of the column | Find table columns with CHAR or VARCHAR type that have a default value that length is longer from the character maximum length of the column. Choose a suitable data type, field size, and default value. If the value is longer, then it is impossible to register it in a field, i.e., it makes registration of data impossible (except if the excessive characters are spaces). | Problem detection | INFORMATION_SCHEMA only | 2022-10-31 10:19 | MIT License | |
131 | Check as to wheteher the names of columns are in the plural or in the singular form (English version) | Check as to wheteher the names of table columns are in the plural or in the singular form. Make sure that you are consistent in naming. | General | INFORMATION_SCHEMA+system catalog base tables | 2023-03-20 13:18 | MIT License | |
132 | Check as to wheteher the names of columns are in the plural or in the singular form (English version) (aggregate view) | Check as to wheteher the names of table columns are in the plural or in the singular form. Make sure that you are consistent in naming. Show the number of columns that name is in plural or in singular by table type. | Sofware measure | INFORMATION_SCHEMA+system catalog base tables | 2023-03-20 13:19 | MIT License | |
133 | Check as to wheteher the names of columns are in the plural or in the singular form (Estonian version) | Check as to wheteher the names of tables are in the plural or in the singular form. Make sure that you are consistent in naming. | General | INFORMATION_SCHEMA+system catalog base tables | 2025-01-15 14:20 | MIT License | |
134 | Check as to wheteher the names of parameters are in the plural or in the singular form (English version) | Check as to wheteher the names of routine parameters are in the plural or in the singular form. Make sure that you are consistent in naming. | General | INFORMATION_SCHEMA+system catalog base tables | 2023-01-16 01:08 | MIT License | |
135 | Check as to wheteher the names of parameters are in the plural or in the singular form (Estonian version) | Check as to wheteher the names of routine parameters are in the plural or in the singular form. Make sure that you are consistent in naming. | General | INFORMATION_SCHEMA+system catalog base tables | 2025-01-15 14:19 | MIT License | |
136 | Check as to wheteher the names of tables are in the plural or in the singular form (English version) | Check as to wheteher the names of tables are in the plural or in the singular form. Make sure that you are consistent in naming. | General | INFORMATION_SCHEMA+system catalog base tables | 2023-01-16 01:09 | MIT License | |
137 | Check as to wheteher the names of tables are in the plural or in the singular form (English version) (aggregate view) | Check as to wheteher the names of tables are in the plural or in the singular form. Make sure that you are consistent in naming. Show the number of tables that name is in plural or in singular by table type. | Sofware measure | INFORMATION_SCHEMA+system catalog base tables | 2023-01-16 01:09 | MIT License | |
138 | Check as to wheteher the names of tables are in the plural or in the singular form (Estonian version) | Check as to wheteher the names of tables are in the plural or in the singular form. Make sure that you are consistent in naming. | General | INFORMATION_SCHEMA+system catalog base tables | 2024-05-31 08:43 | MIT License | |
139 | CHECK constraint cardinality is zero | Write correct constraints. Usually the constraint expression should refer to at least one column. A domain constraint expression should refer to the stub VALUE. For instance, the constraint CHECK(1=0) that is associated with a table T would prevent adding any rows to T. The value of the Boolean expression of this constraint is always FALSE. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2022-04-22 17:06 | MIT License | |
140 | CHECK constraints are inconsistent with DEFAULT values | Find table CHECK constraints that involve two columns that have the same default value. However the constraint assumes that the values must be unequal or one value must be bigger than another. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2024-11-30 09:58 | MIT License |