Check a PostgreSQL Schema Against Wiki Don't Do This Rules from a Desktop GUI
HiDataLinker v1.3.0 Schema Health runs a PostgreSQL schema checkup against wiki Don't Do This–style rules, lists severity, and gives copyable fix SQL that you review and run yourself.
The PostgreSQL wiki keeps a short list of common mistakes under Don't Do This: encodings such as SQL_ASCII, timestamp without time zone, char(n), varchar(n) as a default, money, serial, table inheritance, and CREATE RULE, among others. HiDataLinker is a free, MIT-licensed, local-first desktop client for PostgreSQL and MySQL. In v1.3.0 it ships Schema Health: a PostgreSQL schema checkup that scans the current schema against those catalog rules (and a few related index checks), lists severity, and offers copyable fix SQL. The official PostgreSQL Clients wiki already documents this as a Schema checkup with copyable fix SQL.
What Schema Health actually ships
Open a PostgreSQL connection in HiDataLinker, right-click a schema in the object tree (usually public), and choose Schema health check. The scan is catalog-only and scoped to that schema, except the database encoding check, which looks at the current database.
Findings are grouped by rule and labeled as errors, warnings, or suggestions. Each group names its source: PostgreSQL wiki · Don't Do This, index maintenance, or common practice. For many findings, the app shows fix SQL and an Open fix SQL button that pastes it into the query editor. The UI is explicit: fix SQL is never run automatically — you review it, then press Run yourself. Some findings, such as timetz columns, are marked Needs manual review because a safe conversion depends on a decision the catalog cannot make.
Don't Do This–style catalog rules in v1.3.0 include:
SQL_ASCIIdatabase encodingCREATE RULEand table inheritance- Upper-case table or column names
timestampwithout time zone andtimetz(the wiki and the official date/time types documentation both prefertimestamptzin ordinary use)char(n)and defaultvarchar(n)length limits, as discussed in the character types docsmoneycolumnsserialcolumns — the wiki recommends standard identity columns, available since PostgreSQL 10 (see also serial types)
The same scan also flags a few non-wiki catalog issues: json instead of jsonb, tables with no primary key, unindexed foreign keys, duplicate or invalid indexes, unused indexes, and sequences close to their limit.
Version caveat: the serial → identity fix SQL is meant for PostgreSQL 10+. The timestamp fix SQL assumes existing values are UTC; adjust AT TIME ZONE if they are not. Unused-index findings depend on statistics collected since the last stats reset — check replicas before you drop an index.
Practical path: scan, then review the fix SQL
- Connect locally. Paste a
DATABASE_URLor fill host, port, user, and database. Credentials stay on your machine. There is no seat, connection, or tab freemium wall in the MIT core. - Open the schema. In the object tree, select the PostgreSQL schema you want to check.
- Run Schema Health. Right-click the schema and choose Schema health check. The tab reports how many rules were checked.
- Filter by severity. Use Errors, Warnings, and Suggestions to focus, and read the reason under each rule.
- Open fix SQL when it is offered. Review the statement in the editor — renaming an identifier or changing a column type can lock a table or break application SQL — then run it yourself. Use Check again after you apply changes.
The Don't Do This page also points to schemalint, a related CLI. Schema Health is a desktop GUI checkup in the same spirit, not a claim of schemalint parity or of implementing every wiki rule.
What it does not do
Schema Health is PostgreSQL-only; a MySQL connection has no equivalent menu. It does not lint query-level advice from the wiki (NOT IN, BETWEEN, CURRENT_TIME, psql -W, or trust authentication over TCP/IP). It does not auto-apply fixes, migrate an SQL_ASCII database for you, or rewrite inheritance into declarative partitions automatically.
v1 markets MySQL and PostgreSQL only. The workbench is a native Tauri desktop app, not a heavy Java or Electron shell. Dump and same-engine migrate remain available when you need to copy a PostgreSQL database after you have prepared a properly encoded target, but they are not an encoding-conversion wizard.
Source: github.com/henrybit/HiDataLinker · Overview: /db-client
Soft next step
Need a desktop GUI that can run a PostgreSQL schema lint against wiki Don't Do This rules, with copyable fix SQL you still control?
- Download: https://hidatalinker.onesolo.app/
- Source: https://github.com/henrybit/HiDataLinker