From d30d7f63e88f9a4bdf457c10c23a5966eb103286 Mon Sep 17 00:00:00 2001 From: Andy Davis Date: Sat, 14 May 2011 17:40:45 -0500 Subject: [PATCH] Set order of file hash query to return the latest entry --- product/roundhouse/databases/DefaultDatabase.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/product/roundhouse/databases/DefaultDatabase.cs b/product/roundhouse/databases/DefaultDatabase.cs index 648e8dd6..370ae45d 100644 --- a/product/roundhouse/databases/DefaultDatabase.cs +++ b/product/roundhouse/databases/DefaultDatabase.cs @@ -279,6 +279,7 @@ public string get_current_script_hash(string script_name) DetachedCriteria crit = DetachedCriteria.For() .Add(Restrictions.Eq("script_name", script_name)) + .AddOrder(Order.Desc("id")) .SetMaxResults(1); try