ASM #17435 - Fix hibernate query syntax issue
Change-Id: I2bfd5e927fe97c3348d7366320dc535b6e67f590 Former-commit-id: 4c70c322956fa4a356e06e908a43b80611ae273f
This commit is contained in:
parent
bfeceac493
commit
7c66a2a356
1 changed files with 3 additions and 1 deletions
|
@ -107,6 +107,7 @@ import com.raytheon.uf.edex.database.query.DatabaseQuery;
|
|||
* 06/12/14 #3244 randerso Improved error handling
|
||||
* 09/21/2014 #3648 randerso Changed to do version purging when new databases are added
|
||||
* 10/16/2014 3454 bphillip Upgrading to Hibernate 4
|
||||
* 04/28/2015 17435 randerso Fix getLatestDbIdByModelName().
|
||||
*
|
||||
* </pre>
|
||||
*
|
||||
|
@ -1372,7 +1373,8 @@ public class GFEDao extends DefaultPluginDao {
|
|||
public List<DatabaseID> doInTransaction(
|
||||
TransactionStatus status) {
|
||||
|
||||
Query query = getCurrentSession().createQuery("FROM DatabaseID WHERE siteId = :siteId AND modelName = :modelName ORDER BY modelTime DESC LIMIT 1");
|
||||
Query query = getCurrentSession().createQuery("FROM DatabaseID WHERE siteId = :siteId AND modelName = :modelName ORDER BY modelTime DESC");
|
||||
query.setMaxResults(1);
|
||||
query.setParameter("siteId", siteId);
|
||||
query.setParameter("modelName",modelName);
|
||||
return query.list();
|
||||
|
|
Loading…
Add table
Reference in a new issue