Return-Path: Delivered-To: apmail-db-derby-user-archive@www.apache.org Received: (qmail 94460 invoked from network); 10 Feb 2005 22:11:43 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 10 Feb 2005 22:11:43 -0000 Received: (qmail 17731 invoked by uid 500); 10 Feb 2005 22:11:42 -0000 Delivered-To: apmail-db-derby-user-archive@db.apache.org Received: (qmail 17481 invoked by uid 500); 10 Feb 2005 22:11:41 -0000 Mailing-List: contact derby-user-help@db.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: list-post: List-Id: Reply-To: "Derby Discussion" Delivered-To: mailing list derby-user@db.apache.org Received: (qmail 17467 invoked by uid 99); 10 Feb 2005 22:11:41 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: neutral (hermes.apache.org: local policy) Received: from e31.co.us.ibm.com (HELO e31.co.us.ibm.com) (32.97.110.129) by apache.org (qpsmtpd/0.28) with ESMTP; Thu, 10 Feb 2005 14:11:40 -0800 Received: from westrelay02.boulder.ibm.com (westrelay02.boulder.ibm.com [9.17.195.11]) by e31.co.us.ibm.com (8.12.10/8.12.9) with ESMTP id j1AMBbCI468622 for ; Thu, 10 Feb 2005 17:11:37 -0500 Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by westrelay02.boulder.ibm.com (8.12.10/NCO/VER6.6) with ESMTP id j1AMBb3c436020 for ; Thu, 10 Feb 2005 15:11:37 -0700 Received: from d03av02.boulder.ibm.com (loopback [127.0.0.1]) by d03av02.boulder.ibm.com (8.12.11/8.12.11) with ESMTP id j1AMBbKF006371 for ; Thu, 10 Feb 2005 15:11:37 -0700 Received: from [9.30.40.134] (bandaram.svl.ibm.com [9.30.40.134]) by d03av02.boulder.ibm.com (8.12.11/8.12.11) with ESMTP id j1AMBaDt006326 for ; Thu, 10 Feb 2005 15:11:37 -0700 Message-ID: <420BDC1B.9040903@Sourcery.Org> Date: Thu, 10 Feb 2005 14:11:39 -0800 From: Satheesh Bandaram User-Agent: Mozilla Thunderbird 0.7.3 (Windows/20040803) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Derby Discussion Subject: Re: JDBC driver error codes documentation, where? References: <001801c50ef2$a3d92a40$e3118780@skate> <420A8D47.7090801@Sourcery.Org> <001e01c50ef8$d70dc7d0$e3118780@skate> <420AA24F.4070508@Sourcery.Org> <000a01c50f81$ee9fb910$e3118780@skate> <003201c50fb8$03bd8bc0$e3118780@skate> <003801c50fb8$461c3520$e3118780@skate> In-Reply-To: <003801c50fb8$461c3520$e3118780@skate> X-Enigmail-Version: 0.85.0.0 X-Enigmail-Supports: pgp-inline, pgp-mime Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N All these should go away once Derby Network Client is accepted by the community. Derby can make the retrieveMessages property default to TRUE and remove differences between client properties and Derby properties and the need for a ':' in between... Hopefully soon.. Satheesh Jonathan Eric Miller wrote: > The other thing that is a bit confusing is how there are two different > sets of attributes. One for Derby, one for UDB. > > Jon > > ----- Original Message ----- From: "Jonathan Eric Miller" > > To: "Derby Discussion" > Sent: Thursday, February 10, 2005 3:32 PM > Subject: Re: JDBC driver error codes documentation, where? > > >> One thing to watch out for is that you need the trailing ";". One >> would think that the semi-colon would only act as a delimiter, but, >> you need it at the end of the URL as well. >> >> You have my vote for making the verbose error messages default to on. >> Having them off by default is user/developer hostile IMHO. >> >> Jon >> >> ----- Original Message ----- From: "Jonathan Eric Miller" >> >> To: "Derby Discussion" >> Sent: Thursday, February 10, 2005 9:05 AM >> Subject: Re: JDBC driver error codes documentation, where? >> >> >>> Great, I'll give it a try, thanks! >>> >>> Jon >>> >>> ----- Original Message ----- From: "Satheesh Bandaram" >>> >>> To: "Derby Discussion" >>> Sent: Wednesday, February 09, 2005 5:52 PM >>> Subject: Re: JDBC driver error codes documentation, where? >>> >>> >>>> Yes, you can use that property when you get a connection. Use a URL >>>> like: >>>> 'jdbc:derby:net://localhost:1527/tdb:retrieveMessagesFromServerOnGetMessage=true;user=junk;password=junk;'; >>>> >>>> >>>> Any SQLExceptions on that connection should show the message. You >>>> don't >>>> have to do anything else extra. >>>> >>>> Satheesh >>>> >>>> Jonathan Eric Miller wrote: >>>> >>>>> That looks like a much better error message. Thanks! >>>>> >>>>> What I'm wondering now though, is, is there an equivalent property to >>>>> the JDBC driver itself? Normally, with the other JDBC drivers that >>>>> I've been using (MySQL, MSSQL, Sybase, PostgreSQL, Oracle), it was >>>>> sufficient to just do an Exception.printStackTrace() to get a >>>>> meaningful text message of what went wrong for a SQLException. I'm >>>>> wondering if I'm still going to have to do more than that when using >>>>> the Derby driver? Personally, I think it should print out descriptive >>>>> text by default. >>>>> >>>>> Jon >>>>> >>>>> ----- Original Message ----- From: "Satheesh Bandaram" >>>>> >>>>> To: "Derby Discussion" >>>>> Sent: Wednesday, February 09, 2005 4:23 PM >>>>> Subject: Re: JDBC driver error codes documentation, where? >>>>> >>>>> >>>>>> You can get the error messages using property >>>>>> retrieveMessagesFromServerOnGetMessage, which defaults to FALSE. >>>>>> >>>>>> java -Dij.retrieveMessagesFromServerOnGetMessage=true >>>>>> org..apache.derby.tools.ij >>>>>> ij> connect 'jdbc:derby://localhost:1527/tdb' user 'junk' password >>>>>> 'junk'; >>>>>> ij> INSERT INTO Item (name) VALUES ("Panasonic DVD Player"); >>>>>> ERROR 42X04: Column 'Panasonic DVD Player' is not in any table in >>>>>> the >>>>>> FROM list or it appears within a join specification and is outside >>>>>> the scope of the join specification or it appears in a HAVING clause >>>>>> and is not in the GROUP BY list. If this is a CREATE or ALTER TABLE >>>>>> statement then 'Panasonic DVD Player' is not a column in the target >>>>>> table. >>>>>> ij> >>>>>> >>>>>> IBM actually announced contributing source code for JDBC driver by >>>>>> around March 2005. I think we should make this property default to >>>>>> TRUE in Apache driver, if and when it is accepted by the community. >>>>>> >>>>>> Satheesh >>>>>> >>>>>> Jonathan Eric Miller wrote: >>>>>> >>>>>> Does anyone know where the error codes are listed for the JDBC >>>>>> driver? >>>>>> >>>>>> The following is the error I get in ij if I accidentally use double >>>>>> quotes instead of single quotes. Why oh why doesn't IBM's JDBC >>>>>> driver >>>>>> print intelligible error messages? I can live with it as long as >>>>>> there is documentation somewhere that maps the error codes into >>>>>> descriptive text, but, where is it? >>>>>> >>>>>> Any news on IBM turning over the source code for the JDBC driver? >>>>>> >>>>>> ij> INSERT INTO Item (name) VALUES ("Panasonic DVD Player"); >>>>>> ERROR 42X04: DB2 SQL error: SQLCODE: -1, SQLSTATE: 42X04, SQLERRMC: >>>>>> Panasonic DV >>>>>> D Player�42X04 >>>>>> >>>>>> ij> INSERT INTO Item (name) VALUES ('Panasonic DVD Player'); >>>>>> 1 row inserted/updated/deleted >>>>>> >>>>>> Jon >>>>>> >>>>>> >>>>>> >>>>> >>>>> >>>> >>> >> > >