Skip site navigation (1) Skip section navigation (2)

LEFT JOIN used in psql describe.c

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: PostgreSQL-development <pgsql-hackers(at)postgreSQL(dot)org>
Subject: LEFT JOIN used in psql describe.c
Date: 2005-04-02 03:15:51
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Does anyone know why so many LEFT JOINs are used in psql/describe.c to
join to the pg_namespace table, like here:

      "SELECT c.oid,\n"
      "  n.nspname,\n"
      "  c.relname\n"
      "FROM pg_catalog.pg_class c\n"
      "     LEFT JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace\n");

    processNamePattern(&buf, pattern, false, false,
       "n.nspname", "c.relname", NULL,

I thought a pg_class row always pointed to a valid pg_namespace row because
of our dependency restrictions.

  Bruce Momjian                        |
  pgman(at)candle(dot)pha(dot)pa(dot)us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073


pgsql-hackers by date

Next:From: Bruce MomjianDate: 2005-04-02 03:16:16
Subject: Re: [HACKERS] plPHP in core?
Previous:From: Paul TillotsonDate: 2005-04-02 03:14:07
Subject: Re: Debugging deadlocks

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group