Re: Bound column and serial datatype question

From: lothar(dot)behrens(at)lollisoft(dot)de
To: pgsql-odbc(at)postgresql(dot)org
Subject: Re: Bound column and serial datatype question
Date: 2005-04-23 17:55:34
Message-ID: 426AA836.10599.250D1A8@localhost
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-odbc

Am 23 Apr 2005 um 9:57 hat Marko Ristola geschrieben:

I have solved the problem by shortly unbind the affected column.
The problem, that will stay, is that I do not know, how to detect such
a column by an ODBC call like SQLDescribeCol.

Lothar

>
> If you remove the NOT NULL definition from the CustomerNr,
> you can put there a NULL value too.
>
> The SQL email list is better for these questions, because they have
> more knoledge of these kinds of problems ...
>
> (The CustomerNr and ID columns seem to have redundant information.)
>
> Regards,
> Marko Ristola
>
> lothar(dot)behrens(at)lollisoft(dot)de wrote:
>
> >Hi,
> >
> >I have a table like this:
> >
> >CREATE TABLE Kunden
> >(
> > ID serial NOT NULL,
> > CustomerNr serial NOT NULL,
> > Name CHAR(100),
> > ...
> >);
> >
> >Using bound columns in a form to show the customer data I don´t like to let the user
> >updating the CustomerNr field. This is because, a normal data field is not
> >autogenerated, but these 'serial' data fields.
> >
> >But I like to show the CustomerNr field in the form. Therefore, I simply made the
> >field readonly in the form. But if I insert a new row, the fields data (defaults to 0)
> >would be used as the new value in the table.
> >
> >How to avoid this ?
> >
> >Thanks
> >
> >Lothar
> >
> >--
> >Lothar Behrens www.lollisoft.de
> >Rosmarinstr 3 My public project:
> >40235 Düsseldorf http://sourceforge.net/projects/lbdmf
> >
> >
> >
> >
> >---------------------------(end of broadcast)---------------------------
> >TIP 8: explain analyze is your friend
> >
> >
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
> message can get through to the mailing list cleanly
>

--
Lothar Behrens www.lollisoft.de
Rosmarinstr 3 My public project:
40235 Düsseldorf http://sourceforge.net/projects/lbdmf

In response to

Browse pgsql-odbc by date

  From Date Subject
Next Message Gerard H. Pille 2005-04-23 19:43:45 retrieving images stored by php / pgsql
Previous Message Typing80wpm 2005-04-23 14:37:56 Ambiguities in ODBC Install Parameters