--- gnucash-2.2.1/src/gnome-search/dialog-search.c.orig	2007-10-24 23:30:57.000000000 +0200
+++ gnucash-2.2.1/src/gnome-search/dialog-search.c	2007-10-24 23:30:17.000000000 +0200
@@ -446,6 +446,8 @@
   GList *l;
   gboolean ret;
 
+  if (g_list_length (sw->crit_list) < 1)
+    return TRUE;
   l = g_list_last (sw->crit_list);
   data = l->data;
   ret = gnc_search_core_type_validate (data->element);
@@ -523,7 +525,7 @@
   GtkWidget *element;
   struct _elem_data *data;
 
-  if (g_list_length (sw->crit_list) < 2)
+  if (g_list_length (sw->crit_list) < 1)
     return;
 
   element = g_object_get_data (G_OBJECT (button), "element");
--- gnucash-2.2.1/src/gnome-search/search-string.c.orig	2007-08-19 15:46:20.000000000 +0200
+++ gnucash-2.2.1/src/gnome-search/search-string.c	2007-10-25 05:14:05.000000000 +0200
@@ -176,7 +176,7 @@
   g_return_val_if_fail (fi, FALSE);
   g_return_val_if_fail (IS_GNCSEARCH_STRING (fi), FALSE);
 	
-  if (!fi->value || *(fi->value) == '\0') {
+  if ((!fi->value || *(fi->value) == '\0') && (fi->how != SEARCH_STRING_CONTAINS)) {
     GtkWidget *dialog;
     dialog = gtk_message_dialog_new (NULL,
 				     GTK_DIALOG_MODAL,
