Return-Path: Delivered-To: apmail-jakarta-commons-user-archive@www.apache.org Received: (qmail 39393 invoked from network); 7 Jun 2005 22:31:57 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 7 Jun 2005 22:31:57 -0000 Received: (qmail 27182 invoked by uid 500); 7 Jun 2005 22:31:50 -0000 Delivered-To: apmail-jakarta-commons-user-archive@jakarta.apache.org Received: (qmail 27121 invoked by uid 500); 7 Jun 2005 22:31:50 -0000 Mailing-List: contact commons-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Jakarta Commons Users List" Reply-To: "Jakarta Commons Users List" Delivered-To: mailing list commons-user@jakarta.apache.org Received: (qmail 27087 invoked by uid 99); 7 Jun 2005 22:31:49 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Received: from mitglieder.telcel.com (HELO mitglieder) (200.38.208.219) by apache.org (qpsmtpd/0.28) with ESMTP; Tue, 07 Jun 2005 15:31:48 -0700 Received: from VI5X466 (mitglieder [192.9.195.160]) by mitglieder.telcel.com (iPlanet Messaging Server 5.2 HotFix 1.12 (built Feb 13 2003)) with SMTP id <0IHQ00DW8JY7EP@mitglieder.telcel.com> for commons-user@jakarta.apache.org; Tue, 07 Jun 2005 17:32:32 -0500 (CDT) Date: Tue, 07 Jun 2005 17:31:34 -0500 From: Alfredo Ledezma Melendez Subject: [DbUtils] Handling null values during an update In-reply-to: <42A5F3EE.5010506@starbak.net> To: Jakarta Commons Users List Reply-to: alfredo.ledezma@gmail.com Message-id: MIME-version: 1.0 X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1441 X-Mailer: Microsoft Outlook IMO, Build 9.0.6604 (9.0.2911.0) Content-type: TEXT/PLAIN Content-transfer-encoding: 8BIT Importance: Normal X-Priority: 3 (Normal) X-MSMail-priority: Normal X-Virus-Checked: Checked X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Hello, I've been using dbutils with mysql, postgresql, even with SQL Server successfully for quite a long time. But now I'm facing a little problem with Oracle9i (thin-driver and jdbc-odbc). I have a table with two fields of type DATE; when I try to UPDATE a row using methos update from QueryRunner in this table using null values, it throws the exception: java.sql.SQLException: Invalid column type Query: UPDATE factura SET fechaFacturacion = ?, fechaPedido = ? WHERE folioECAC = ? Parameters: [null, null, 278] However, using not null values it runs perfect. I've been looking in some forums and they say the problem is that driver does not how to set null values for those values of the table. Is there any workaround, somebody has solved this problem before, should I use PreparedStatement instead of QueryRunner? Any help would be really appreciated. Best regards, ____________________________________________ Alfredo Ledezma Mel�ndez. Gerencia de Sistemas CRM Consultor Externo de Sistemas de Atenci�n a Clientes RadioMovil DIPSA, S. A. de C. V. Ej�rcito Nacional No. 488, Col. Anahuac, C.P. 11570 M�xico D.F. --------------------------------------------------------------------- To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: commons-user-help@jakarta.apache.org