pg.ddx.io  pgsql-odbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Hiroshi Inoue <Inoue@tpf.co.jp>
To: Bruce Momjian <pgman@candle.pha.pa.us>
Cc: Jim Holliday <jholliday@aurigin.com>
Cc: pgsql-odbc@postgresql.org
Subject: Re: bug in info.c file - incorrect SQL
Date: Sat, 4 Jan 2003 09:20:04 +0900
Message-ID: <EKEJJICOHDIEMGPNIFIJCEJIKDAA.Inoue@tpf.co.jp> (raw)
In-Reply-To: <200301032117.h03LHCX10106@candle.pha.pa.us>

> -----Original Message-----
> From: Bruce Momjian [mailto:pgman@candle.pha.pa.us]
>
> Hiroshi Inoue wrote:
> > -----Original Message-----
> > From: Jim Holliday
> >
> > > For the ODBC driver psqlodbc.dll version 7.02.0003 there is
> an error in
> > the info.c.
> > > In 2 places the SQL contains an alias in the FROM clause for the
> > pg_namespace
> > > table and then references the table in the where clause.  The
> below cut
> > from the
> > > info.c file should replace all instances on pg_namespace. in the where
> > clause with
> > > pn. This should be done in both places.
> >
> > Does the code give you a wrong result in the first place ?
>
> I see what Hiroshi is saying now --- there was a reference to
> pg_namespace (in WHERE but not in FROM) _and_ a reference to 'pn' as an
> alias for pg_namespace (in WHERE and FROM).
>
> The attached patch fixes this by creating a pn1 and pn2 alias for
> pg_namespace in FROM.  It also improves some of the alias tags.  Applied
> to ODBC CVS.  Can someone run some tests on these?

I've already changed my local source.
I would replace your change with my code.

regards,
Hiroshi Inoue




view thread (14+ messages)  latest in thread

Message-ID: <EKEJJICOHDIEMGPNIFIJCEJIKDAA.Inoue@tpf.co.jp>
Permalink:  ../EKEJJICOHDIEMGPNIFIJCEJIKDAA.Inoue@tpf.co.jp/
Also on:    postgresql.org/message-id/EKEJJICOHDIEMGPNIFIJCEJIKDAA.Inoue@tpf.co.jp

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-odbc@postgresql.org
  Cc: Inoue@tpf.co.jp, pgman@candle.pha.pa.us, jholliday@aurigin.com
  Subject: Re: bug in info.c file - incorrect SQL
  In-Reply-To: <EKEJJICOHDIEMGPNIFIJCEJIKDAA.Inoue@tpf.co.jp>
  References: <200301032117.h03LHCX10106@candle.pha.pa.us> <EKEJJICOHDIEMGPNIFIJCEJIKDAA.Inoue@tpf.co.jp>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox