As It seems your entity Country has not been enhanced by the enhancer.
If you are using Intellij Idea there is an option in the project's
properties dialog which specifies which packages to be enhanced.
You can get more information about enhancement from
http://db.apache.org/jdo/enhancement.html
Regards,
Miroslav
On 04/15/2010 01:56 PM, Vik wrote:
Hie
I have a Entity class Country.
The very first time when i am running my app this is not created in
datastore.
So my code:
try{
String query = "select from " + BloodDonorCountryList.class.getName() +
" where countryName == \"" + country.toLowerCase() + "\"";
log.info <http://log.info>("Query is:" + query);
List<BloodDonorCountryList> countryList =
(List<BloodDonorCountryList>) pm.newQuery(query).execute();
log.info <http://log.info>("returning: :::::::::::::::::::::::::");
if(countryList.isEmpty())
return null;
return countryList;
}catch(Exception e){
log.severe("Method: addBloodDonorCountry");
log.severe(e.getClass().getName() + " " + e.getMessage());
throw new CommandExecuteException("Problem while querying country list.");
}
throws exception saying:
EVERE: javax.jdo.JDOUserException Persistent class "Class
vik.sakshum.Country does not seem to have been enhanced. You may want
to rerun the enhancer and check for errors in the output." has no
table in the database, but the operation requires it. Please check the
specification of the MetaData for this class.
So how to avoid this exception? Or in other words how to detect if
this is the case.
Thankx and Regards
Vik
Founder
www.sakshum.com <http://www.sakshum.com>
www.sakshum.blogspot.com <http://www.sakshum.blogspot.com>
--
You received this message because you are subscribed to the Google
Groups "Google App Engine for Java" group.
To post to this group, send email to
[email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-appengine-java?hl=en.
--
You received this message because you are subscribed to the Google Groups "Google
App Engine for Java" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-appengine-java?hl=en.