I got the problem
solved.....whewwwwwwwwwwwwwwwwwww!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!


Here is my  OLD daoHibernate:



public class TravelAgentUserDaoHibernate extends GenericDaoHibernate<User,
Long> implements TravelAgentUserDao {

    public TravelAgentUserDaoHibernate() {
        super(User.class);
    }

 public List<User> getListTravelAgentUsers() {
          log.debug("88888888888888888888" + getSession().createQuery(" from
User as u, TravelAgent as t "
                                + " where u.travelAgent.id = t.id and "
                                + " u.hotelGroup.id is NULL ").list());
        return getSession().createQuery(" from User as u, TravelAgent as t "
                                + " where u.travelAgent.id = t.id and "
                                + " u.hotelGroup.id is NULL ").list();

             
    }


}

---------------------------

Here is my  New daoHibernate:

 public List<User> getListTravelAgentUsers() {


         log.debug("88888888888888888888" +
this.getHibernateTemplate().findByNamedQuery("findAllTravelAgentUsers"));

        return 
this.getHibernateTemplate().findByNamedQuery("findAllTravelAgentUsers");
   
    }

-----------------------------

and the Named Query  just above the User class is given below :---

@NamedQuery (

    name = "findAllTravelAgentUsers",

    query = "select u from User as u where u.travelAgent.id is NOT NULL and
u.hotelGroup.id is NULL"

)


------------

Anyway, Thanks Matt for pointing the error. I guess my SQL query is not good
when using createQuery. It is easier to check out the query using MySQL  and
then put it in the name query......

Well Thanks once again,

your little Greenhorn.
:jumping:
-- 
View this message in context: 
http://www.nabble.com/Need-Help%3A--WARN--btpool0-1--LookupUtil.%3Cinit%3E%2899%29-%7C-Exception%3A--.LookupUtil--Error-looking-up-property-%22username%22-in-object-type-%22-Ljava.lang.Object-%22.-Cause%3A-Unknown-property-%27username%27%0D%0Ajava.lang.NoSuchMethodException%3A-Unknown-property-%27username%27-tp17230235s2369p17247330.html
Sent from the AppFuse - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to