Hi Alex, I'm curious as to why:
at ch.rodano.msbase.model.Patient.patientWithPKInContext(Patient.java:30) is in your stack trace? What does that method do? Thanks, /dev/mrg On 8/31/07, Alexander Lamb (dev) <[EMAIL PROTECTED]> wrote: > Hello list, > > We are experimenting a Cayenne crash and wondering how to get around it. > > Here is the place of the crash: > > java.lang.NullPointerException > at org.apache.cayenne.query.BaseQueryMetadata.resolve > (BaseQueryMetadata.java:97) > at org.apache.cayenne.query.SelectQuery.getMetaData(SelectQuery.java: > 151) > at org.apache.cayenne.util.ObjectContextQueryAction.<init> > (ObjectContextQueryAction.java:69) > at org.apache.cayenne.access.DataContextQueryAction.<init> > (DataContextQueryAction.java:46) > at > org.apache.cayenne.access.DataContext.onQuery(DataContext.java:1387) > at org.apache.cayenne.access.DataContext.performQuery > (DataContext.java:1376) > at ch.rodano.msbase.model.Patient.patientWithPKInContext > (Patient.java:30) > > I am not certain how to check the line were it crashed (looking at > the code repository on-line does not probably garantee the line > number is the same). > > We are simply trying to get a list of objects: > > SelectQuery allPatients = new SelectQuery(Patient.class); > List patients = dataContext.performQuery(allPatients); > > Probably something is wrong with our model, but what? How to find out? > The only different thing we did (which we did already previously) is > that the primary key for Patient is a varchar (String) and is not > hidden in the Java Class. > > Thanks for any hints (we regenerated everyting, etc... always the > same crash) > > Alex