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 2E7108BA46E for ; Fri, 18 Feb 2005 14:34:04 +0000 (GMT) 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 25628-01 for ; Fri, 18 Feb 2005 14:33:42 +0000 (GMT) Received: from web20821.mail.yahoo.com (web20821.mail.yahoo.com [216.136.227.134]) by svr1.postgresql.org (Postfix) with SMTP id 244018B9EFC for ; Fri, 18 Feb 2005 14:33:45 +0000 (GMT) Received: (qmail 71459 invoked by uid 60001); 18 Feb 2005 14:33:45 -0000 Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; b=sBMW3IxNczf3e5/KF0OnKYItSDyGXB3Id8C3/r5x+kNSGWyyWgY6bu7Weq48ljvc4NxgzWRauycjh48IlgdpTjARCWehTk1D8o57lEv1zFZUkqFC5jc5+RYEnpiGmRkP/qPM0GN2lOvBNxlRBOAL9Xih/nKHqwgq3fErHalJXgg= ; Message-ID: <20050218143345.71457.qmail@web20821.mail.yahoo.com> Received: from [24.248.12.141] by web20821.mail.yahoo.com via HTTP; Fri, 18 Feb 2005 06:33:45 PST Date: Fri, 18 Feb 2005 06:33:45 -0800 (PST) From: Jeff Eckermann Subject: Re: Inserting dates instead of varchar? To: "Schuhmacher, Bret" , pgsql-odbc@postgresql.org In-Reply-To: <98E4F4D46DACD0479C96D7356D5C37356B04E8@sac1exch3.aspect.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.369 tagged_above=0 required=5 tests=AWL, DNS_FROM_RFC_ABUSE X-Spam-Level: X-Archive-Number: 200502/85 X-Sequence-Number: 4975 --- "Schuhmacher, Bret" wrote: > Hello all - I've checked the bug list and didn't > see > anything, so here goes... > > I have the following dataset I want to store in > PostgreSQL (this shows two columns): > > 1009 Timeout/Invalid Entries. HRSC Top menu. > 1010 0 out. Main NCAL menu. > 1014 NCAL Employment Verification. > 1019 Timeout/Invalid Entries. Main NCAL menu. > 1024 NCAL Direct Deposit. > 2050 0 out. SCAL Benefits menu. > 2052 SCAL 401K plans. > 2053 SCAL Life & LTD Insurance. > 2054 SCAL Spending Accounts. > 2055 SCAL Retirement Information. > 2059 Timeout/Invalid Entries. SCAL Benefits menu. > > My table has two columns: > CREATE TABLE dnismap > ( > dnis varchar(40) NOT NULL, > dnisdesc varchar(150), > CONSTRAINT dnismap_pkey PRIMARY KEY (dnis) > ) > WITH OIDS; > ALTER TABLE dnismap OWNER TO postgres; > GRANT ALL ON TABLE dnismap TO postgres; > GRANT ALL ON TABLE dnismap TO public; > > When I attempt to insert this data this table via > the ODBC driver I get *dates* (without time or tz) > instead of the given data, like this: > > dnis dnisdesc > 2005-02-17 00:00:00 2005-02-17 00:00:00 Bizarre. Try ODBC logging, if you aren't already, and check to see what queries are being sent to PostgreSQL. What interface are you using to handle the inserting? > > This is on Win2KAS, with PostgreSQL 8.0.1, and the > PostgreSQL ODBC driver v8.00.00.04 that came with my > windows setup package I downloaded today from the > PostgreSQL.org site. > > The application that uses the ODBC DSN and does the > inserting > has been well tested with Oracle and TimesTen ODBC > drivers. > This is my first attempt at using PostgreSQL with > this application, though. > > Can anyone provide any insight into this odd issue? > Is there a mapping issue when binding text into > varchar fields or something? > > Thanks in advance, > > Bret > -- > Bret A. Schuhmacher > Sr. Architect > Aspect Communications > 1310 Ridder Park Drive > San Jose, CA  95131 >   > 423.837.7563 Office/Mobile > www.aspect.com > > > ---------------------------(end of > broadcast)--------------------------- > TIP 5: Have you checked our extensive FAQ? > > http://www.postgresql.org/docs/faq > __________________________________ Do you Yahoo!? Yahoo! Mail - 250MB free storage. Do more. Manage less. http://info.mail.yahoo.com/mail_250