Received: from localhost (maia-4.hub.org [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id AE7379FA20E for ; Tue, 19 Dec 2006 03:38:56 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-new, port 10024) with ESMTP id 05463-08 for ; Tue, 19 Dec 2006 03:38:51 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from floppy.pyrenet.fr (news.pyrenet.fr [194.116.145.2]) by postgresql.org (Postfix) with ESMTP id E83FC9F9386 for ; Tue, 19 Dec 2006 03:38:50 -0400 (AST) Received: by floppy.pyrenet.fr (Postfix, from userid 106) id CB69530DF1; Tue, 19 Dec 2006 08:38:49 +0100 (MET) From: "lothar.behrens@lollisoft.de" X-Newsgroups: pgsql.interfaces.odbc Subject: Re: Still SQLSetPos problem even with minimal sample, SQL_NULL_DATA Date: 18 Dec 2006 23:38:43 -0800 Organization: http://groups.google.com Lines: 53 Message-ID: <1166513923.246513.71300@73g2000cwn.googlegroups.com> References: <1165751917.708138.93120@j72g2000cwa.googlegroups.com> <457CACE1.2090907@tpf.co.jp> <1165848049.639913.7360@n67g2000cwd.googlegroups.com> <457DF1D9.7080804@tpf.co.jp> <1165955153.386694.185060@f1g2000cwa.googlegroups.com> <457F4E43.108@tpf.co.jp> <1166311419.967140.317720@16g2000cwy.googlegroups.com> <1166482424.555811.255330@j72g2000cwa.googlegroups.com> <458726EE.6040906@tpf.co.jp> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-Complaints-To: groups-abuse@google.com In-Reply-To: <458726EE.6040906@tpf.co.jp> User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322; .NET CLR 2.0.50727; InfoPath.1),gzip(gfe),gzip(gfe) X-HTTP-Via: 1.1 firewall:10080 (squid/2.5.STABLE7) Complaints-To: groups-abuse@google.com Injection-Info: 73g2000cwn.googlegroups.com; posting-host=217.6.158.130; posting-account=ZEv0oQwAAAARGOrW-5pO2M_10hQ_J_Pj To: pgsql-odbc@postgresql.org X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200612/81 X-Sequence-Number: 8528 Hiroshi Inoue schrieb: > lothar.behrens@lollisoft.de wrote: > > Hi, > > > > I have implemented setting SQL_COLUMN_IGNORE, SQL_NULL_DATA and have > > added functions > > to indicate this state. > > > > I have made a 'small' sample application to demonstrate this, but I > > still use my ODBC wrapper > > classes in that sample application. You may get access to the full > > code. Ask for it! > > > > The first insert is with valid foreign keys and no column set to NULL. > > This insert works. > > My next insert has set the columns to NULL, but it inserts the values > > of the last insert. > > > > > Currently I have made an array of long (cbBufferLength[2]) and set this > > explicitely short before > > the call to SQLSetPos: > > > > if (mode == 1) // 1 means adding > > cbBufferLength[1] = SQL_NULL_DATA+SQL_COLUMN_IGNORE; > > else > > cbBufferLength[0] = SQL_NULL_DATA+SQL_COLUMN_IGNORE; > > At first glance, adding SQL_NULL_DATA(=-1) and SQL_COLUMN_IGNORE(=-6) > seems to have no meaning. > If you really want to set to NULL on SQL_ADD, please set SQL_NULL_DATA. > If you want to set DEFAULT on SQL_ADD, please set SQL_COLUMN_IGNORE. > Ahh, I misunderstood you. I will try that today. regards, Lothar > regards, > Hiroshi Inoue > > ---------------------------(end of broadcast)--------------------------- > TIP 3: Have you checked our extensive FAQ? > > http://www.postgresql.org/docs/faq