浏览 1410 次
该帖已经被评为隐藏帖
|
|
---|---|
作者 | 正文 |
发表时间:2007-06-18
老是提示 Hibernate operation: could not execute query; bad SQL grammar [select account0_.accountid as accountid, account0_.username as username0_, account0_.password as password0_ from login.account account0_ where account0_.username=? and account0_.password=?]; nested exception is java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]对象名 'login.account' 无效。 这是我的DAO的代码 引用 public Account getUser(final Account account) { String hql = "from Account a where a.username = ? and a.password = ?"; List list = getHibernateTemplate().find(hql, new Object[]{account.getUsername(),account.getPassword()}); if(null == list || 0 == list.size()){ return null; } return (Account)list.get(0); } 很奇怪不知道哪里有问题了 声明:ITeye文章版权属于作者,受法律保护。没有作者书面许可不得转载。
推荐链接
|
|
返回顶楼 | |