Seq nr | Name▲ | Goal | Type | Data source | Last update | License | ... |
---|---|---|---|---|---|---|---|
901 | Too generic names (user-defined types, domains) | Find names of user-defined types and domains that contain too generic (noise) words. | Problem detection | system catalog base tables only | 2021-10-31 17:41 | MIT License | |
902 | Too many slashes in regular expressions | Find patterns of regular expressions where more than \ is written instead of \, e.g., \\s is used instead of \s to refer to a character class. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2024-12-21 11:15 | MIT License | |
903 | Too short domain constraint names | Find names of domain constraints that are shorter than the length of the name of the domain + two characters. | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
904 | Too short names of database objects | "Names in software are 90 percent of what make software readable. You need to take the time to choose them wisely and keep them relevant. Names are too important to treat carelessly. Names should not cause confusion." (Robert C. Martin, Clean Code) The names should be meaningful and searchable. Find the names (identifiers) of user-defined database objects that are shorter than three characters. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2024-12-21 17:27 | MIT License | |
905 | Too short or missing comments of derived tables and routines | Find views, materialized views, and user-defined routines that do not have a comment at all or the comment is shorter than twice the length of the object name, or the comment states that it is missing (TODO). You should give information to future developers and maintainers of the system (including the future version of yourself). Do not just repeat the name in the comment (with perhaps some rewording). | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2023-01-19 12:56 | MIT License | |
906 | Too short table constraint names | The names should be expressive. Find names of constraints, which are associated directly to a table, that are shorter than the length of the name of the table + two characters. | Problem detection | system catalog base tables only | 2021-02-25 17:29 | MIT License | |
907 | Too short view names | Names should be expressive. Find views that name is shorter than the average length of the the names of its directly underlying tables (both base tables and derived tables). | Problem detection | INFORMATION_SCHEMA only | 2021-02-25 17:29 | MIT License | |
908 | Too wide composite indexes | Find composite indexes that do not support any constraint but are on more than three columns. | Problem detection | system catalog base tables only | 2021-11-06 02:40 | MIT License | |
909 | Too wide derived (dependent) table | Find derived tables (views, materialized views) that are based on more than five tables and that have more than 15 columns. This view might produce "a denormalized world view" where all the data is together in one table and applications make queries based on this single view to fulfill their specific tasks. Such view does not follow the separation of concerns principle. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2022-12-13 12:34 | MIT License | |
910 | Transform method does not return | Find user-defined SQL and PL/pgSQL routines that do not return a value although the name suggest that it should return a value (contains "_to_"). | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2023-01-14 19:37 | MIT License | |
911 | Trigger functions with a conditional statement | Find trigger functions that contain a conditional (IF or CASE) but do not contain a SELECT statement before these. The latter condition is for the reason that one cannot use a subquery in the WHEN clause. Thus, if one wants to make a query and decide the further action based on the results of the query, then one must do it within the body of the function. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2023-11-19 12:07 | MIT License | |
912 | Trigger is used to enforce referential integrity | Find tables where user-defined (non-system) triggers are used to implement referential integrity. In addition to table name show the triggers and the number of triggers. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2021-02-25 17:30 | MIT License | |
913 | Trigger routines with TG_OP variable that are not associated with a suitable trigger | Automatically defined TG_OP variable in a trigger function has data type text. Its value is a string of INSERT, UPDATE, DELETE, or TRUNCATE telling for which operation the trigger was fired. Find the routines that according to the TG_OP value must react to a certain operation but the routine is not associated with any triggers that are fired by the operation. For instance, the routine specifies reaction to DELETE operation but the routine is not associated with any DELETE trigger. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2021-12-25 01:26 | MIT License | |
914 | Triggers that are used to calculate tsvector values react to a wrong set of events | Find triggers on base tables that are used to calculate tsvector values that react to a wrong set of events, i.e., react to the DELETE event or do not react to the INSERT and UPDATE events. | Problem detection | system catalog base tables only | 2023-11-07 10:14 | MIT License | |
915 | Triggers with arguments from the CREATE TRIGGER statement | Find triggers that get an argument from the CREATE TRIGGER statement. | General | INFORMATION_SCHEMA+system catalog base tables | 2023-12-22 12:35 | MIT License | |
916 | Triggers with SELECT (i.e., probably check data based on another table) | If a trigger is used for enforcing a constraint, then it should take into account that due to the implementation of multiversion concurrency control (MVCC) in PostgreSQL, reading data does not block data modification and vice versa. Thus, there may be a need to lock the entire table or some row explicitly. | General | INFORMATION_SCHEMA+system catalog base tables | 2020-11-06 14:51 | MIT License | |
917 | Triggers with the same name in different schemas | Find trigger names that are used in a database in more than one schema. Different things should have different names. But here different triggers have the same name. Also make sure that this is not a duplication. | General | INFORMATION_SCHEMA+system catalog base tables | 2020-11-06 14:51 | MIT License | |
918 | Triggers with the same name within the same schema | Find names of triggers that are used within the same schema more than once. Give different triggers different names. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2021-02-25 17:30 | MIT License | |
919 | Tsvector values are not automatically calculated | Find base table columns with tsvector type in case of which it is not a generated column nor does the table has an associated trigger to calculate the tsvector value automatically. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2023-11-07 11:45 | MIT License | |
920 | Unbalanced brackets | Write expressions correctly. Find code fragments that have unbalanced brackets, i.e., the number of opening brackets is not the same as the number of closing brackets. | Problem detection | INFORMATION_SCHEMA+system catalog base tables | 2024-01-24 16:02 | MIT License |