Seq nr | Name▲ | Goal | Type | Data source | Last update | License | ... |
---|---|---|---|---|---|---|---|
1 | Address field size is incorrect (too short or too long) | Find base table columns that are meant for recording different types of addresses where the filed size does not take into account the possible maximum length. | Problem detection | INFORMATION_SCHEMA only | 2023-11-09 12:55 | MIT License | |
2 | A getter does not return a value | Find user-defined SQL and PL/pgSQL routines that do not return a value although the name suggest that it should return a value (starts with "get"). | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2023-01-06 14:24 | MIT License | |
3 | All columns of a base table have a default value | Find base tables where all the columns have a default value. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
4 | All the non-primary key columns are optional | Find base tables where all he non-primary key columns are optional. Avoid too many optional columns. You have to be extra careful with NULLs in case of formulating search conditions of data manipulation statements. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:30 | MIT License | |
5 | All unique keys have at least one optional column | Find base tables where all unique keys (sets of columns covered by a unique constraint, or a unique index) have at least one optional column. In this case there can be rows in the table where the values that should identify the row are missing. Because NULL is not a value and is not duplicate of another NULL the, follwing is possible: CREATE TABLE Uniq(a INTEGER NOT NULL, b INTEGER, CONSTRAINT ak_uniq UNIQUE (a, b)); INSERT INTO Uniq(a, b) VALUES (1, NULL); INSERT INTO Uniq(a, b) VALUES (1, NULL); | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2023-10-21 11:54 | MIT License | |
6 | A non-parameterized table function instead of a view | Find table functions that do not have any parameters. Prefer simpler and more portable solutions. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2021-11-03 21:16 | MIT License | |
7 | A predefine character class has been incorrectly specified | Find regular expressions where a predefined character class is incorrectly specified, e.g. [digit] instead of [:digit:]. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2023-11-23 12:09 | MIT License | |
8 | A routine is invoked only once | Find user-defined routines that are invoked by exactly one user-defined routine. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2024-12-22 14:53 | MIT License | |
9 | A setter does not update a table | Find user-defined non-trigger SQL and PL/pgSQL routines that name starts with "set" (but not with "setting") but do not contain a UPDATE statement. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2022-11-27 18:35 | MIT License | |
10 | A state machine is implemented with the help of an enumeration type | Find implementations of state machines that uses an enumeration type. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2023-11-26 15:39 | MIT License | |
11 | A table has the same name as a routine | Find table names that are the same as some routine name. Use different names to avoid confusion. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2021-02-25 17:30 | MIT License | |
12 | Base table column name is the same as its domain name | Find base table columns that have the same name as the domain name or the data type name of the column. The names may have different uppercase/lowercase characters. Columns, domains, and types are different concepts in SQL and perhaps it is better to use different names in case of these. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
13 | Base table column of comments/descriptions has an incorrect data type or maximum character length | Find base table columns that name refers to the possibility that these are used to register comments/descriptions. Find the columns where the data type is not VARCHAR and TEXT or in case of VARCHAR the maximum number of permitted characters is smaller than 1000. In case of determining field sizes choose a size that permits registration of all possible legal values. | Problem detection | INFORMATION_SCHEMA only | 2022-05-01 13:39 | MIT License | |
14 | Base table column of measurements does not have a correct data type | Find base table columns that name refers to the possibility that these are used to register measurement results. Find the columns that do not have an integer or numeric type. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
15 | Base table column of national identification numbers does not have a correct data type | Find non-textual base table columns that name refers to the possibility that these are used to register national identification numbers (personal codes). The codes can contain additional symbols to numbers. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
16 | Base table column of national identification numbers has a too short field size | Find base table columns with VARCHAR type that name refers to the possibility that these are used to register national identification numbers (personal codes). Find the columns where the field size is shorter than 20. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
17 | Base table column of personal names has questionable properties | Find base table columns that name refers to the possibility that these are used to register personal names. Although there are very long personal names the general approach is to register a shortened version of these. Thus, a large field size is not a good idea because it would cause usability and security problems. There are persons who only have one name (mononymous persons). Database design must take it into account. | Problem detection | INFORMATION_SCHEMA only | 2022-10-29 20:35 | MIT License | |
18 | Base table column of quantities does not have a numeric type (based on column names) | Find base table columns that name refers to the possibility that these are used to register quantities of things. Find the columns that do not have a numeric type. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
19 | Base table column of sums of money does not have a numeric type (based on column names) | Find base table columns that name refers to the possibility that these are used to register prices/sums of money. Find columns that do not have a numeric type. | Problem detection | INFORMATION_SCHEMA only | 2021-03-21 11:45 | MIT License | |
20 | Base table column of sums of money has too big or small scale | Find base table columns that name refers to the possibility that these are used to register data about prices/sums of money. Find the columns that have decimal type but have a too big (bigger than six) or a too small scale (zero). The selection of field size must be precise and should take into account the possible data in the column. | Problem detection | INFORMATION_SCHEMA only | 2021-03-21 11:45 | MIT License |