pg.ddx.io  pgsql-odbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Hiroshi Inoue <inoue@tpf.co.jp>
To: the6campbells <the6campbells@gmail.com>
Cc: pgsql-odbc@postgresql.org
Subject: Re: sqlDescribeCol not setting null flag correctly for sqlDescribeCol
Date: Wed, 30 Sep 2009 15:22:24 +0900
Message-ID: <4AC2F920.1000403@tpf.co.jp> (raw)
In-Reply-To: <22431f1b0909290825o42e55baahe3d514ad1f918867@mail.gmail.com>
References: <22431f1b0909290825o42e55baahe3d514ad1f918867@mail.gmail.com>

the6campbells wrote:
> 
> A basic table is described where one column has a null 
> constraint: create table TNUM( RNUM integer not null, CNUM numeric(7,2)  )
> A simple view is defined that projects all the columns of said 
> table: create view VNUM as select * from TNUM
> A query which projects the columns of the table or the view will return 
> inconsistent null flags when you call sqlDescribeCol after sqlPrepare
> 
> Does not matter if you have parse, server side prepare etc 
> enabled/disabled. 
> 
> Looks like another bug to me. 

It seems very hard for the driver to get more accurate results
  than psql does. I see the following result via psql.

xxxxx=> \d tnum
         Table "public.tnum"
  Column |     Type     | Modifiers
--------+--------------+-----------
  rnum   | integer      | not null
  cnum   | numeric(7,2) |

xxxxx=> \d vnum
         View "public.vnum"
  Column |     Type     | Modifiers
--------+--------------+-----------
  rnum   | integer      |
  cnum   | numeric(7,2) |
View definition:
  SELECT tnum.rnum, tnum.cnum
    FROM tnum;

regards,
Hiroshi Inoue




view thread (2+ messages)

Message-ID: <4AC2F920.1000403@tpf.co.jp>
Permalink:  ../4AC2F920.1000403@tpf.co.jp/
Also on:    postgresql.org/message-id/4AC2F920.1000403@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, the6campbells@gmail.com
  Subject: Re: sqlDescribeCol not setting null flag correctly for sqlDescribeCol
  In-Reply-To: <4AC2F920.1000403@tpf.co.jp>
  References: <22431f1b0909290825o42e55baahe3d514ad1f918867@mail.gmail.com> <4AC2F920.1000403@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