public boolean LoginById(Tcsuserinfo tcsuserinfo) throws Exception { 
boolean flag = false; 
System.out.println(tcsuserinfo.getCsuserno()); 
System.out.println(tcsuserinfo.getPassword()); 
// String hql = "FROM Tcsuserinfo AS t WHERE t.csuserno=? AND t.password=?"; 
                String hql = "FROM Tcsuserinfo"; 
Query q = this.getSession().createQuery(hql); 
// q.setString(0,tcsuserinfo.getCsuserno()); 
// q.setString(1,tcsuserinfo.getPassword()); 
System.out.println(hql); 
System.out.println(q.list().size()); 
List l = q.list(); 
if(l.size()>0){ 
flag = true; 
tcsuserinfo.setUsername(((Tcsuserinfo)l.get(0)).getUsername()); 

return flag; 

请问为什么hql语句String hql = "FROM Tcsuserinfo AS t WHERE t.csuserno=? AND t.password=?"; 
这样写会有问题,简单的登陆验证,可是"FROM Tcsuserinfo";这样写就一点问题都没有,我认为是AS这里有问题,可是不知道如何解决,我用的是hibernate3,oracle10G 数据库