function _sqlIfThen(const condition: boolean; const OnTrue, OnFalse: string): string;
begin
case condition of
false : result := OnFalse;
true : result := OnTrue;
end;
end;
function _sqlProtectFieldData(const FieldData: string): string;
begin
result := _sql_Apostrophe+FieldData+_sql_Apostrophe;
end;
<hr size="2" width="100%" />
if cree then
begin
SqlQuery1.Close;
SqlQuery1.SQL.BeginUpdate;
try
SqlQuery1.SQL.Clear;
SqlQuery1.SQL.text :=
{ begin query }