Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WNVJQ-0006RH-Js for pgsql-interfaces@arkaria.postgresql.org; Tue, 11 Mar 2014 22:38:16 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1WNVJP-00044e-V6 for pgsql-interfaces@arkaria.postgresql.org; Tue, 11 Mar 2014 22:38:15 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WNVJA-00044J-01 for pgsql-interfaces@postgresql.org; Tue, 11 Mar 2014 22:38:00 +0000 Received: from smtp129.dfw.emailsrvr.com ([67.192.241.129]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1WNVJ0-0001P4-Lr for pgsql-interfaces@postgresql.org; Tue, 11 Mar 2014 22:37:57 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp29.relay.dfw1a.emailsrvr.com (SMTP Server) with ESMTP id 8CA243987FE for ; Tue, 11 Mar 2014 18:37:46 -0400 (EDT) X-Virus-Scanned: OK Received: by smtp29.relay.dfw1a.emailsrvr.com (Authenticated sender: david.wall-AT-yozons.com) with ESMTPSA id 1688D398699 for ; Tue, 11 Mar 2014 18:37:45 -0400 (EDT) Message-ID: <531F903A.5030604@computer.org> Date: Tue, 11 Mar 2014 15:37:46 -0700 From: David Wall User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.3.0 MIME-Version: 1.0 To: pgsql-interfaces@postgresql.org Subject: Re: Which Java class in the new java.time package shall be used to mapped timestamp? References: <1821595371.107318.1394574876616.JavaMail.mail@webmail16> In-Reply-To: <1821595371.107318.1394574876616.JavaMail.mail@webmail16> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-interfaces Precedence: bulk Sender: pgsql-interfaces-owner@postgresql.org On 3/11/2014 2:54 PM, Vernon E wrote: > I have tried both LocalDateTime (without time zone informatio) and > ZonedDateTime (with time zone information) in the new java.time > package and get a same error: > column "registeration_datetime" is of type timestamp without time zone but expression is of type bytea > Hint: You will need to rewrite or cast the expression. > > Which class I shall use? java.sql.Timestamp is the normal type that maps to a PG timestamp field, and I'd recommend TIMESTAMP WITH TIME ZONE unless you are sure the time part is really not important. -- Sent via pgsql-interfaces mailing list (pgsql-interfaces@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-interfaces