Seq nr | Name | Goal | Type | Data source▲ | Last update | License | ... |
---|---|---|---|---|---|---|---|
121 | Optional base table columns | Find optional base table columns, i.e., columns that permit NULLs. Are you sure you want to allow NULLs in these columns? | General | INFORMATION_SCHEMA only | 2020-11-21 03:02 | MIT License | |
122 | Optional base table columns that have a default value that is not the empty string | Find optiona base table columns that have a default value that is not the empty string. Such columns should be mandatory. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
123 | Optional columns before mandatory columns | Find cases where optional columns are before a mandatory column. Place mandatory columns before optional columns to improve comprehensibility of the table. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
124 | Optional foreign key columns | Find foreign key columns that do not have the NOT NULL constraint. It is better to limit the use of NULLs and optional columns due to the problems that it causes in interpreting the query results, making queries, and enforcing constraints. In addition, one should check as to whether this kind of design is consistent with the multiplicities in the conceptual data model. | General | INFORMATION_SCHEMA only | 2023-11-17 18:36 | MIT License | |
125 | Pairs of base tables that have at least two columns with the same names and data types | What are the pairs of base tables that have at least two columns with the same names and data types. The tables might violate the principle of orthogonal design and hence might facilitate uncontrolled data redundancy over different tables. | Problem detection | INFORMATION_SCHEMA only | 2022-11-09 13:13 | MIT License | |
126 | Percentage of optional columns in each base table | What is the percentage of optional columns (that permit NULLs) in case of each base table? It is better to prohibit the use of NULLs in as many columns as possible. Otherwise the results of queries may be misleading. | Sofware measure | INFORMATION_SCHEMA only | 2020-11-08 20:55 | MIT License | |
127 | Perhaps an unnecessary default value (the empty string or a string that consists of only whitespace) of a base table column/domain | Find table columns and domains with the default value that is the empty string or a string that consists of only whitespace (for instance, newlines, spaces). | Problem detection | INFORMATION_SCHEMA only | 2021-03-20 11:42 | MIT License | |
128 | Perhaps a redundant column (based on sequence generators) | Find base tables where more than one column gets the default value by using the sequence generator mechanism. | Problem detection | INFORMATION_SCHEMA only | 2021-03-05 09:42 | MIT License | |
129 | Perhaps a state machine is implemented with timestamp columns | Find implementations of state machines that uses a set of columns with a timestamp type. | Problem detection | INFORMATION_SCHEMA only | 2021-03-26 21:04 | MIT License | |
130 | Perhaps a too simplified state machine | Find base table columns with Boolean type that name refers to the possibility that these are used to register as to whether an entity is currently in active state or not. Find the base tables that have exactly one Boolean column. During the system design one should find all the possible states of an entity type that influence the behavior of the information system. Data as to whether an entity is in one of these states should be in the database. Having only two states - active/inactive - is sometimes a too big simplification. | Problem detection | INFORMATION_SCHEMA only | 2021-03-27 03:08 | MIT License | |
131 | Perhaps checking of file extension is incorrect | Find check constraints of tables that use a regular expression to check as to whether a registered string ends with an appropriate file extension. However, the expression does not put the dot sign into the square brackets nor does have the escape character \before it, i.e., it is interpreted as a single character not as the dot sign in the expression. In regular expressions the dot (.) matches any single character except the newline character. | Problem detection | INFORMATION_SCHEMA only | 2023-11-08 15:29 | MIT License | |
132 | Perhaps default value 'infinity' is missing | Find optional base table columns that have a timestamp type and do not have a default value. | Problem detection | INFORMATION_SCHEMA only | 2023-11-12 11:52 | MIT License | |
133 | Perhaps incorrect column name (based on default values) | Find columns of base tables that have the default value CURRENT_USER or SESSION_USER but the name of the column does not refer to the fact that it contains usernames. | Problem detection | INFORMATION_SCHEMA only | 2024-01-01 12:14 | MIT License | |
134 | Perhaps incorrect default vale | Find columns of base tables that have default value CURRENT_USER. | Problem detection | INFORMATION_SCHEMA only | 2023-12-30 11:32 | MIT License | |
135 | Perhaps incorrect WHEN clause | Find row level triggers that have action condition (WHEN clause) but the Boolean expression in its specifications does not refer to neither NEW nor OLD variable. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:30 | MIT License | |
136 | Perhaps IS DISTINCT FROM should be used instead of <> in WHEN clauses | Use a right predicate in trigger condition in order to ensure that the trigger executes always when it has to but not more often. IS DISTINCT FROM treats NULL as if it was a known value, rather than unknown. It would be relevant if a column that is referenced in the action condition is optional, i.e., permits NULLs. | General | INFORMATION_SCHEMA only | 2020-12-24 14:30 | MIT License | |
137 | Perhaps the column type should be UUID | Find base table columns that do not have uuid type but the name of the column refers to the possibility that the values in the column are uuid's. | Problem detection | INFORMATION_SCHEMA only | 2022-06-09 15:07 | MIT License | |
138 | Perhaps the precision in case of a base table column with NUMERIC/DECIMAL type is too small | Make sure that in case of using the type DECIMAL/NUMERIC as the type of a base table column the precision (the permitted number of digits in the number) is not too small. For instance, the biggest value in the type NUMERIC(1,1) is 0.9. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
139 | Perhaps the type of a base table column/domain should be BOOLEAN (based on types and default values) | Find base table columns and domains that have a textual type and the default value that represents a truth-value. For instance, the type of a column could be VARCHAR and the column has the default value 'TRUE'. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:30 | MIT License | |
140 | Perhaps the type of a base table column/domain should be INTEGER/SMALLINT/BIGINT (based on sequence generators) | Specify for each column/domain a right data type that takes into account expected values in the column/domain. Find base table columns and domains that refer to the nextval function by using the default value mechanism but do not have the type INTEGER, SMALLINT, or BIGINT. This check is performed in case of identity columns: ERROR: identity column type must be smallint, integer, or bigint. | Problem detection | INFORMATION_SCHEMA only | 2021-03-04 11:24 | MIT License |