Re: put carriage return into VARCHAR2 using PL/SQL
Date: 1996/09/07
Message-ID: <842097401snz_at_wbriscoe.demon.co.uk>#1/1
In article <50ple4$fgj_at_inet-nntp-gw-1.us.oracle.com>
surman_at_dlsun338.us.oracle.com "Scott Urman" writes:
> In article <x6eloeng4ue.fsf_at_mdt26awm.i-have-a-misconfigured-system-so-shoot-me>,> Ming-Ding Tsao <mtsao_at_cas.org> writes:
> |>
> |> Question: In R7.3.2 using PL/SQL how to put the carriage return(0x0d
> |> or 0x0a) into a string ?
> |>
> |>
> |> For example:
> |>
> |> achar VARCHAR2(16);
> |>
> |> achar := 'test' || ' ' || 'line' || ' ';
> |>
> |> -- how to put a line feed to replace the last ' ' above.
I was messing about in this area yesterday and found that:
achar := 'test
line
';
dbms_output.put_line(achar); results in:
test
line
You can also use chr as was suggested elsewhere but that was the behavior I was looking for.
-- Walter BriscoeReceived on Sat Sep 07 1996 - 00:00:00 CEST