Re: [Q]: Entering a carriage return into a LONG column using SQL*Plus

From: <yxfindat_at_corp00.d51.lilly.com>
Date: 1995/06/06
Message-ID: <1995Jun6.103125.1_at_corp00.d51.lilly.com>#1/1


In article <3qre93$aee_at_ixnews4.ix.netcom.com>, rsingh_at_ix.netcom.com (Rashpal Singh) writes:
>
> If I have a table:
>
> MASTER_TABLE
> ID NUMBER
> TEXT LONG
>
> and I needed to insert following data into this table
> (which includes carriage returns, denoted as <CR> in
> my insert statement below:
>
> INSERT INTO MASTER_TABLE
> VALUES (1, 'This is first line' ||
> <CR>
> 'This is line two');
>
>
> The only problem is that when i enter a Return,
> SQL*Plus stops prompting for additional lines.
> How can I get around this problem? Is there an
> escape character I can use to escape the Return ?
>
> Thanks for any suggestions/comments.

Try

INSERT INTO MASTER_TABLE
VALUES (1, 'This is first line' || chr(10) || 'This is line two');

I have a feeling the chr(10) may be system dependant. Try CHR(13) if it does not work.

Simon Received on Tue Jun 06 1995 - 00:00:00 CEST

Original text of this message