Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Advanced hql

 
paulo fe
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello every body!!!
i have a object Person :
public class Person {
private String name;
private Adress add;
}
and i have the clause select p.add from Person as p
but this query return the object Adress and i want
that query return the Person object with a Adress and name
with the default value (null or some else..)..
heelllp!!!
 
Peter Laurinec
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Query: "from Person p" will return all persistent objects from the database.
Then you can normally refer to Person attributes(name,add).
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic