X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id A4FE6534FE for ; Sat, 23 Apr 2005 14:55:20 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 51102-02 for ; Sat, 23 Apr 2005 17:55:09 +0000 (GMT) Received: from Mail2.KONTENT.De (mail2.kontent.de [81.88.34.59]) by svr1.postgresql.org (Postfix) with ESMTP id 1EB6B535A5 for ; Sat, 23 Apr 2005 14:55:04 -0300 (ADT) Received: from jedi.behrens.de (p508CDF18.dip0.t-ipconnect.de [80.140.223.24]) by Mail2.KONTENT.De (Postfix) with ESMTP id ECE21388046 for ; Sat, 23 Apr 2005 19:55:01 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by jedi.behrens.de (Postfix) with ESMTP id 03A26398D8 for ; Sat, 23 Apr 2005 19:54:16 +0200 (CEST) Received: from jedi.behrens.de ([127.0.0.1]) by localhost (jedi [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 21246-01 for ; Sat, 23 Apr 2005 19:54:13 +0200 (CEST) Received: from anakin (anakin.behrens.de [192.168.150.240]) by jedi.behrens.de (Postfix) with ESMTP id 673541D832 for ; Sat, 23 Apr 2005 19:54:12 +0200 (CEST) From: lothar.behrens@lollisoft.de To: pgsql-odbc@postgresql.org Date: Sat, 23 Apr 2005 19:55:34 +0200 MIME-Version: 1.0 Subject: Re: Bound column and serial datatype question Message-ID: <426AA836.10599.250D1A8@localhost> In-reply-to: <4269F1C7.7090906@kolumbus.fi> References: <4264FEFB.10829.EB6968@localhost> X-mailer: Pegasus Mail for Windows (4.21c, DE v4.21c R1a) Content-type: text/plain; charset=ISO-8859-1 Content-transfer-encoding: Quoted-printable Content-description: Mail message body X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.254 tagged_above=0 required=5 tests=AWL, FORGED_RCVD_HELO, NO_REAL_NAME X-Spam-Level: X-Archive-Number: 200504/64 X-Sequence-Number: 5223 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.behrens@lollisoft.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=B4t 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 simpl= y 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=FCsseldorf 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@postgresql.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=FCsseldorf http://sourceforge.net/projects/lbdmf