Skip site navigation (1) Skip section navigation (2)

Re: date value not geting inserted properly

From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: "surabhi(dot)ahuja" <surabhi(dot)ahuja(at)iiitb(dot)ac(dot)in>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: date value not geting inserted properly
Date: 2006-06-07 12:30:41
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-generalpgsql-jdbc
surabhi.ahuja wrote:

> stmt.setObject(i + 1, (tagV.value),
>         ((TypeAttrib) (primaryKeyMap_.get(tMap.get(temp)))).dataType);
> can u please tell as to what should the dataType be for date, isnt it 
> 91- integer?

java.sql.Types.DATE is 91, which should be correct if you're inserting a 
bare date (with no time part).

What is the type and value of the "tagV.value" object?

What driver version and server version are you using?

What is the query you are executing?

Can you provide a selfcontained testcase showing the problem? You 
haven't really given us enough info to go on here.


In response to


pgsql-jdbc by date

Next:From: Jan de VisserDate: 2006-06-07 12:42:20
Subject: Re: PostgreSQL XA & EJB container
Previous:From: surabhi.ahujaDate: 2006-06-07 11:54:33
Subject: date value not geting inserted properly

pgsql-general by date

Next:From: Filip RembiaƂkowskiDate: 2006-06-07 13:09:18
Subject: Re: COLLATE
Previous:From: chris smithDate: 2006-06-07 12:25:16
Subject: Re: ean code data type

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group