Return-Path: Delivered-To: apmail-openjpa-users-archive@locus.apache.org Received: (qmail 55133 invoked from network); 2 Apr 2008 17:42:48 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 2 Apr 2008 17:42:48 -0000 Received: (qmail 48694 invoked by uid 500); 2 Apr 2008 17:42:48 -0000 Delivered-To: apmail-openjpa-users-archive@openjpa.apache.org Received: (qmail 48524 invoked by uid 500); 2 Apr 2008 17:42:47 -0000 Mailing-List: contact users-help@openjpa.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@openjpa.apache.org Delivered-To: mailing list users@openjpa.apache.org Received: (qmail 48515 invoked by uid 99); 2 Apr 2008 17:42:47 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Apr 2008 10:42:47 -0700 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [77.75.108.10] (HELO mail.ukfsn.org) (77.75.108.10) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 02 Apr 2008 17:41:56 +0000 Received: from localhost (smtp-filter.ukfsn.org [192.168.54.205]) by mail.ukfsn.org (Postfix) with ESMTP id 3F42FDECBA for ; Wed, 2 Apr 2008 18:48:00 +0100 (BST) Received: from mail.ukfsn.org ([192.168.54.25]) by localhost (smtp-filter.ukfsn.org [192.168.54.205]) (amavisd-new, port 10024) with ESMTP id TJQKe-yccOu9 for ; Wed, 2 Apr 2008 18:08:56 +0100 (BST) Received: from stargate.local (84-45-236-142.no-dns-yet.enta.net [84.45.236.142]) by mail.ukfsn.org (Postfix) with ESMTP id 477E1DECE7 for ; Wed, 2 Apr 2008 18:47:59 +0100 (BST) From: David Goodenough To: users@openjpa.apache.org Subject: Re: Please make Exceptions more useful... Date: Wed, 2 Apr 2008 18:41:50 +0100 User-Agent: KMail/1.9.7 References: <200804021346.18018.david.goodenough@btconnect.com> <23CFBB81-3848-4165-8AC8-01A324A8CA07@SUN.com> In-Reply-To: <23CFBB81-3848-4165-8AC8-01A324A8CA07@SUN.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-15" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200804021841.50218.david.goodenough@btconnect.com> X-Virus-Checked: Checked by ClamAV on apache.org On Wednesday 02 April 2008, Craig L Russell wrote: > Hi David, > > Excellent comment. Can you please file a JIRA so we can track this > request? > > Thanks, > > Craig > > On Apr 2, 2008, at 5:46 AM, David Goodenough wrote: > > I just got an error message which said:- > > > > Exception in thread "main" > general > > error> org.apache.openjpa.persistence.PersistenceException: > > java.util.Date > > cannot be cast to java.util.Collection > > > > In this (and the accompanying stack trace) there is no indication > > which Date > > object cannot be cast to a Collection. Yes from the stack trace I > > know that > > I was trying to persist a particular root object, but I have no idea > > which > > class and field this error refers to. Simply adding the class and > > field would > > make debugging so much easier. > > > > Then once I know which Date field it might be, I can start to try to > > work out > > why it wanted to cast it to a collection. Presumably this was it > > was trying > > to map this to a particular table, or to a set of objects of a given > > type, and > > again it would be useful to know what application object as opposed > > to raw > > java class it was trying to map to. > > > > David > > Craig Russell > Architect, Sun Java Enterprise System http://java.sun.com/products/jdo > 408 276-5638 mailto:Craig.Russell@sun.com > P.S. A good JDO? O, Gasp! Which module should it be attached to? David