Re: Creating dynamically-typed tables using psycopg2's built-in formatting

From: Daniele Varrazzo <daniele(dot)varrazzo(at)gmail(dot)com>
To: Sebastiaan Mannem <sebastiaan(dot)mannem(at)enterprisedb(dot)com>
Cc: Daniel Cohen <daniel(dot)m(dot)cohen(at)berkeley(dot)edu>, Christophe Pettus <xof(at)thebuild(dot)com>, psycopg(at)postgresql(dot)org
Subject: Re: Creating dynamically-typed tables using psycopg2's built-in formatting
Date: 2019-06-14 19:12:54
Message-ID: CA+mi_8aMcR3uhZHjdDkWfx_zJ9NgnHL9U_injEjg62wA5+7YUg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: psycopg

On Fri, Jun 14, 2019 at 6:44 PM Sebastiaan Mannem <
sebastiaan(dot)mannem(at)enterprisedb(dot)com> wrote:

> Yeah,
> "schema.tbl" will search all schemas in search path for a table explicitly
> called "schema.tbl".
> So that will never find a table called "tbl", and most probably never find
> a table at all.
>

Also note that from psycopg 2.8 you can use Identifier("schema", "tbl") to
represent a dot-separated sequence of identifiers.

http://initd.org/psycopg/docs/sql.html#psycopg2.sql.Identifier

-- Daniele

In response to

Responses

Browse psycopg by date

  From Date Subject
Next Message Daniel Cohen 2019-06-14 20:41:02 Re: Creating dynamically-typed tables using psycopg2's built-in formatting
Previous Message Sebastiaan Mannem 2019-06-14 17:44:07 Re: Creating dynamically-typed tables using psycopg2's built-in formatting