{
  "id": 2741593,
  "title": "PostgreSQL psql: Schema Navigation Quick Reference",
  "url": "https://urgent.news/2026/08/23/postgresql-psql-schema-navigation-quick-reference",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-08-23T06:43:36.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/amelye_chatila_717552aace/postgresql-psql-schema-navigation-quick-reference-113b"
  },
  "original_language": "en",
  "account": "Navigating PostgreSQL databases, schemas, and objects can be easily accomplished using the psql command line interface. This refresher provides a quick guide to the most useful commands.\n\nTo list all schemas in the database, simply use the command \\dn. If you want more detailed information about each schema, add the plus sign: \\dn+. To check the current schema search path, use the command SHOW search_path; You can set this path for the current session with the command SET search_path TO schema_name ;.\n\nListing databases is straightforward with the command \\l. To switch to a different database, use the command \\c database_name. The current connection can be viewed with \\conninfo, while the current database is shown with the command SELECT current_database (); The current user is displayed with SELECT current_user ;.\n\nTo list the tables within the current schema, use the command \\dt. For tables in a specific schema, specify the schema name: \\dt schema_name . * . To view all tables across all schemas, use \\dt * . * . Additional information about tables can be displayed with \\dt +.\n\nTo examine the structure of a table, run \\d table_name. For more detailed information, use \\d+ table_name. Other database objects such as views, functions, indexes, and sequences can be listed using \\dv, \\df, \\di, and \\ds respectively. All installed extensions can be seen with \\dx.\n\nOnce you've completed your navigation tasks, you can exit psql by typing \\q. These commands should cover the basic navigation and object discovery needs when working with PostgreSQL from the command line.",
  "summary": "A short refresher for navigating PostgreSQL databases, schemas, and objects from the psql command line. Schemas List all schemas: \\ dn List schemas with additional information: \\ dn + Check the current schema search path: SHOW search_path ; Set the schema search path for the current session: SET search_path TO schema_name ; Databases List databases: \\ l Connect to another database: \\ c…",
  "key_points": [],
  "editors_take": null,
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}