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

AND
AND
AND
ANDFrom where does the query gets its information?
AND
AND

There are 961 queries.

Seq nrNameGoalTypeData sourceLast updateLicense...
561Perhaps inconsistent use of temporal functionsFind routines that use temporal functions CURRENT_TIMESTAMP, LOCALTIMESTAMP, or now() that is inconsistent with the default values of the columns that are used by the routine, e.g., function uses a column with the default value LOCALTIMESTAMP but the routine uses function CURRENT_TIMESTAMP or now().Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-12-10 17:11MIT License
562Perhaps incorrect check of permitted timestamp valuesFind base table columns with a timestamp type and a simple check constraint that checks as to whether the timestamp values are within an appropriate range of values. Find constraints where the check of the upper bound of the range is perhaps incorrect.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-11-09 10:27MIT License
563Perhaps incorrect use of 'NULL'Find Boolean expressions, queries, routines, and default values that refer to value 'NULL'. Perhaps NULL was intended instead. 'NULL' is a string (a value) but NULL is a special marker for denoting missing value.Problem detectionINFORMATION_SCHEMA+system catalog base tables2021-11-04 13:19MIT License
564Perhaps is not a snake case - date, time, or by is not preceded by an underscoreFind names that perhaps do not use the snake_case naming style because the name ends with the phrase "date", "time", "by" that is not preceded by an underscore. Prefer snake_case over PascalCase and camelCase in names.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-12-06 12:12MIT License
565Perhaps is not snake_case - Boolean-indicating prefix without underscoreFind names of types, domains, columns, and parameters that perhaps do not use the snake_case naming style because the name starts with "is", "has", or "on" that is not followed by an underscore. Prefer snake_case over PascalCase and camelCase in names.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-12-06 11:46MIT License
566Perhaps is not snake_case - id, code, key, or nr is not followed by an underscoreFind names that perhaps do not use the snake_case naming style because the name starts with the phrase "id", "uuid", "code" , "kood", "key", or "nr" that is not followed by an underscore. Prefer snake_case over PascalCase and camelCase in names.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-11-15 17:19MIT License
567Perhaps is not snake_case - id, code, key, or nr is not preceded by an underscoreFind names that perhaps do not use the snake_case naming style because the name ends with the phrase "id", "uuid", "code", "kood", "key", or "nr" that is not preceded by an underscore. Prefer snake_case over PascalCase and camelCase in names.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-12-31 11:17MIT License
568Perhaps is not snake_case - long subsections without underscoresFind names that perhaps do not use the snake_case naming style because the name contains a long subsection (at least 20 characters) without underscores. Prefer snake_case over PascalCase and camelCase in names.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-03-18 16:47MIT License
569Perhaps last update time trigger is missingFind base tables that have a column for last update time but the table does not have associated before update row level trigger for changing the last update time.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-12-30 15:22MIT License
570Perhaps spaces are unnecessarily restrictedFind base table columns that name refers to the possibility that the column is used to record names or textual descriptions but the column seems to have a simple check constraint that restricts spaces in these.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-11-18 13:30MIT License
571Perhaps the name referes to multiple conceptsFind database objects that name contains words "and" (English) or "ja" (Estonian).Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-03-16 20:42MIT License
572Perhaps the type of a base table column/domain should be BOOLEAN (based on CHECK constraints)Find base table columns and domains that have a CHECK constraint that limits possible values in a manner that seems to indicate that the permitted values represent truth values, i.e., permitted values are 0/1 or true/false.Problem detectionINFORMATION_SCHEMA+system catalog base tables2021-02-25 17:29MIT License
573Perhaps the type of a base table column should be BOOLEAN (based on column names)Find base table columns that based on the name seem to hold truth values. Find columns that name starts with "is_" or "has_" or "can_" or "on_" and that do not have Boolean type.Problem detectionINFORMATION_SCHEMA+system catalog base tables2024-01-03 09:41MIT License
574Perhaps the type of a base table column should be BOOLEAN (based on enumerated types)Find base table columns that have an enumerated type that seems to emulate Boolean type.Problem detectionINFORMATION_SCHEMA+system catalog base tables2021-02-25 17:30MIT License
575Perhaps the type of a parameter should be BOOLEAN (based on parameter names)Find routine parameters that based on the name seem to hold truth values. Find parameters that name starts with "is_" or "has_" or "can_" or "on_" and that do not have Boolean type.Problem detectionINFORMATION_SCHEMA+system catalog base tables2024-01-03 00:10MIT License
576Perhaps too many different prefixes in the names of database objects that have the same typeOne should be consistent in naming, including in the use of prefixes. If you use prefix in the name of a database object, then it should refer to the type of the database object. Do not use different prefixes in the names of database objects that have the same type. Find types of database objects in case of which there are different prefixes in different names.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-03-18 17:16MIT License
577Perhaps too many different suffixes in the names of database objects that have the same typeOne should be consistent in naming, including in the use of suffixes. If you use sufix in the name of a database object, then it should refer to the type of the database object. Do not use different suffixes in the names of database objects that have the same type. Find types of database objects in case of which there are different suffixes in different names.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-03-17 11:14MIT License
578Perhaps too many input parametersToo many parameters (in this case four or more) could be a sign of not separating concerns and having a routine that has more than one task.Problem detectionINFORMATION_SCHEMA+system catalog base tables2021-11-04 10:57MIT License
579Perhaps too many square bracketsCharacter classes are surrounded by two pairs of square brackets.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-11-15 10:47MIT License
580Perhaps unnecessary DECLARE section in a PL/pgSQL routineFind PL/pgSQL routines that perhaps unnecessarily contain DECLARE section. More specifically, find routines with the DECLARE section where the only task seems to be raising an exception. The query excludes the cases where the error message is constructed dynamically, i.e., in this case using a variable maybe justifiable.Problem detectionINFORMATION_SCHEMA+system catalog base tables2023-12-30 10:19MIT License