Hi Francesca,
Here is a guess... Your mapping doesn't use Java package name (which
happens to be "test") for entities. Try doing this:
1. Select a DataMap - you should see a screen like that -
http://objectstyle.org/cayenne/modelerguide/common-tasks/datamap-defaults.html
2. For "Java Package" type "test"
3. Click "Update" button next to "Java Package" field.
4. Save mapping.
Hope this helps.
Andrus
> hi!
> I have done these commands:
>
> C:\cayenne\cayenne-1.1\src\tutorials\cayenne-cmd-app>set
> CLASSPATH=C:\cayenne\cayenne-1.1\src\tutorials\cayenne-cmd-app\java\test
> ; C:\cayenne\cayenne-1.1\lib\cayenne.jar
>
> C:\cayenne\cayenne-1.1\src\tutorials\cayenne-cmd-app>C:\j2sdk1.4.2_06\bin\javac
> java\test\*.java
>
> and these are OK, but then there is an error::
>
> C:\cayenne\cayenne-1.1\src\tutorials\cayenne-cmd-app>set
> CLASSPATH=C:\cayenne\cayenne-1.1\src\tutorials\cayenne-cmd-app\java
>
> C:\cayenne\cayenne-1.1\src\tutorials\cayenne-cmd-app>C:\j2sdk1.4.2_06\bin\java
> test.Main metro
>
> INFO QueryLogger: Created connection pool:
> jdbc:mysql://localhost/database1
> Driver class: com.mysql.jdbc.Driver
> Min. connections in the pool: 1
> Max. connections in the pool: 1
> WARN EntityResolver: *** Class 'Artist' not found in runtime. Ignoring.
> WARN EntityResolver: *** Class 'Gallery' not found in runtime.
> Ignoring. WARN EntityResolver: *** Class 'Painting' not found in
> runtime. Ignoring. Exception in thread "main"
> org.objectstyle.cayenne.CayenneRuntimeException: [v.1
> .1 December 6 2004] No DataMap found for query with root: class
> test.Gallery
> at org.objectstyle.cayenne.access.DataDomain.performQueries
> (DataDomain.j
> ava:633)
> at org.objectstyle.cayenne.access.DataContext.performQueries
> (DataContext
> .java:1408)
> at org.objectstyle.cayenne.access.Transaction.performQueries
> (Transaction
> .java:179)
> at org.objectstyle.cayenne.access.DataContext.performQueries
> (DataContext
> .java:1366)
> at org.objectstyle.cayenne.access.DataContext.performQuery
> (DataContext.j
> ava:1622)
> at org.objectstyle.cayenne.access.DataContext.performQuery
> (DataContext.j
> ava:1485)
> at test.Main.findGallery(Main.java:64)
> at test.Main.runTutorial(Main.java:38)
> at test.Main.main(Main.java:30)
>
>
>
>
> What can I do?
>
>
> thanks you very much!!!
>
> francesca
This archive was generated by hypermail 2.0.0 : Fri Mar 04 2005 - 10:36:57 EST