开发者

select certain "column" for JDO entity

I have a entity in the appengine datastore called DataBase wh开发者_JAVA技巧ich contains some attributes or columns or what ever it is named in JDO,I want to select only some columns from that entity so i use select statment like that

 String query = "select from " + DataBase.class.getName()+" where id == '"+user+"'";
List<DataBase> greetings = (List<DataBase>) pm.newQuery(query).execute();

so i select all things in that entity its id=user...fine.I actually want to get certain column from that list and put it in a separate list so i can do some functionality on it can somebody help???


You can't select individual columns in App Engine. Entities are stored as serialized protocol buffers, so they're retrieved as a unit, not individually.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜