What's strange is that this was working fine, even on MySQL, the last time I played with it. Unfortunately that was a bit of time ago so I don't have a good reference to narrow this down.
I'll try some things on Derby and see if I can reproduce it, and with more detailed steps to do so. -David On Feb 23, 2010, at 9:49 PM, Adrian Crum wrote: > I was unable to reproduce the problem in the Example component using Derby. > > -Adrian > > --- On Tue, 2/23/10, David E Jones <d...@me.com> wrote: > >> From: David E Jones <d...@me.com> >> Subject: entity-one no longer converting types (probably a >> GenericEntity.setAllFields issue) >> To: dev@ofbiz.apache.org >> Date: Tuesday, February 23, 2010, 8:32 PM >> >> Has anyone made any changes GenericEntity.setAllFields >> method or the code underneath it? It no longer works unless >> the primary key consists only of String type fields. >> >> This is easy to reproduce, even in the Example Application, >> by trying to work with ExampleFeatureAppl records, which >> have a fromDate as part of the primary key. >> >> This warning is showing, and the underlying code does not >> work (on MySQL at least): >> >> >> [java] 2010-02-23 21:22:42,706 >> (http-0.0.0.0-8443-1) [ >> GenericEntity.java:422:WARN ] >> [java] ---- exception report >> ---------------------------------------------------------- >> [java] =-=-=-=-=-=-=-=-= Database >> type warning GenericEntity.set =-=-=-=-=-=-=-=-= In entity >> field [ProductFeatureAndAppl.fromDate] set the value passed >> in [java.lang.String] is not compatible with the Java type >> of the field [java.sql.Timestamp] >> [java] Exception: >> java.lang.Exception >> [java] Message: Location of >> database type warning >> [java] ---- stack trace >> --------------------------------------------------------------- >> [java] java.lang.Exception: >> Location of database type warning >> [java] >> org.ofbiz.entity.GenericEntity.set(GenericEntity.java:422) >> [java] >> org.ofbiz.entity.GenericEntity.set(GenericEntity.java:368) >> [java] >> org.ofbiz.entity.GenericEntity.setAllFields(GenericEntity.java:885) >> [java] >> org.ofbiz.entity.finder.PrimaryKeyFinder.runFind(PrimaryKeyFinder.java:105) >> [java] >> org.ofbiz.entity.finder.PrimaryKeyFinder.runFind(PrimaryKeyFinder.java:81) >> [java] >> org.ofbiz.widget.screen.ModelScreenAction$EntityOne.runAction(ModelScreenAction.java:523) >> >> -David >> >> >> > > >