Subject | Re: [firebird-support] Re: Inserting CR/LF to a string using ISQL |
---|---|
Author | Steve Wiser |
Post date | 2012-02-17T13:56:04Z |
On Fri, Feb 17, 2012 at 6:49 AM, patrick_marten <patrick_marten@...>wrote:
into foo (test) values ('Hello' || ASCII_CHAR(13) || ASCII_CHAR(10) ||
'world');
-steve
--
Steve Wiser
President
Specialized Business Software
6325 Cochran Road, Unit 1
Solon, OH 44139
www.specializedbusinesssoftware.com
www.docunym.com
(440) 542-9145 - fax (440) 542-9143
Toll Free: (866) 328-4936
[Non-text portions of this message have been removed]
> **Basically you can concatenate the newline characters using a UDF: insert
>
>
> Hello,
>
> ist there an alternative for this?
>
> > In a script you can use this:
> >
> > insert into foo (test) values ('Hello
> > world');
>
> The reason is: I'm generating my "insert into"-lines in Excel. Once one of
> the cells contains a linebreak, the copied value from Excel has an " at the
> beginning and at the end, which breaks the SQL script.
>
> I seem not to be able to find a solution in / for Excel, so I thought that
> Firebird might have a solution for such a case.
>
> I would try to replace the linebreaks in Excel with required chars etc.,
> so that the script still works and also the linebreaks don't get lost and
> get inserted correctly.
>
> See http://www.firebirdfaq.org/faq132/
into foo (test) values ('Hello' || ASCII_CHAR(13) || ASCII_CHAR(10) ||
'world');
-steve
--
Steve Wiser
President
Specialized Business Software
6325 Cochran Road, Unit 1
Solon, OH 44139
www.specializedbusinesssoftware.com
www.docunym.com
(440) 542-9145 - fax (440) 542-9143
Toll Free: (866) 328-4936
[Non-text portions of this message have been removed]