{
if (search == null || search.length() == 0)
return null;
String text = "%" + search.toLowerCase() + "%";
HBCIDBService service = (HBCIDBService) Settings.getDBService();
DBIterator list = service.createList(SepaLastschrift.class);
list.addFilter("LOWER(zweck) LIKE ? OR " +
"LOWER(empfaenger_name) LIKE ? OR " +
"LOWER(creditorid) LIKE ? OR " +
"LOWER(mandateid) LIKE ? OR " +
"LOWER(endtoendid) LIKE ? OR " +
"LOWER(empfaenger_konto) LIKE ?",
text,text,text,text,text,text);
list.setOrder("ORDER BY " + service.getSQLTimestamp("termin") + " DESC");
ArrayList results = new ArrayList();
while (list.hasNext())
{
results.add(new MyResult((SepaLastschrift)list.next()));