Subject Re: CR/LF in SQL
Author peter_jacobi.rm
Hi Christion,

--- Christian Gütter <news@g...> wrote:
> I would like to do the following Delphi code sample in SQL:
>
> NameAll := Name1 + #13#10 + Name2;
>
> I guess that in SQL it must be something like:
>
> NameAll = Name1 || ??? || Name2
>
> My problem is that I do not know how CR/LF is represented in
> SQL.

SQL itself, as implemented in FB1.5, doesn't have a
general escaping mechanism (there is one in the newest
SQL standard, so it may be one day in FB).

But for your app it's a Delphi question, isn't it?

In C you would write: "NameAll = Name1 || '\x0d\x0a' || Name2"

You use the escaping mechanism of the host language and the
actual CR/LF bytes are sent to the DBMS.

Regards,
Peter Jacobi