Bist du sicher, dass du keine Quotes(') in deinem RichEdit hast?
Versuchs mal so:
Delphi-Quellcode:
Ds.SelectSQL.Text := 'SELECT *' + #13#10 +
'FROM xyz' + #13#10 +
'WHERE field1 LIKE ' QuotedStr(RichEdit1.Text);
// Oder
Ds.SelectSQL.Text := 'SELECT *' + #13#10 +
'FROM xyz' + #13#10 +
'WHERE field1 LIKE '+#39+'%'+StringReplace(RichEdit1.Text,#39,#39#39,[rfReplaceAll])+'%'+#39;