diff --git a/lib/ajax_forms/dsl.rb b/lib/ajax_forms/dsl.rb
index <HASH>..<HASH> 100755
--- a/lib/ajax_forms/dsl.rb
+++ b/lib/ajax_forms/dsl.rb
@@ -23,11 +23,11 @@ module ActiveAdminAjaxForms
         if !params[:q_id].blank?
           params[:q]={:id_equals => params[:q_id]} #selected element
         elsif groupping_condition.nil?
-          params[:q]={:g=>{"0"=>{:name_cont=>search_term}}}
+          params[:q]={:g=>{"0"=>{:name_cont_all=>search_term.split(" ")}}}
         end
 
         @q = @model.search(params[:q])
-        @items = @q.result.order('name asc').limit(100).map { |item| {:id => item.id, :text => item.to_s} }
+        @items = @q.result.order('id desc', 'name asc').limit(100).map { |item| {:id => item.id, :text => item.to_s} }
         respond_to do |format|
           format.json { render :json => @items }
         end
add order by default and cont all method for search with split of text search