Newline Characters in Quoted Strings
By default, the string constant must be written on a single line.
That is, you cannot use embedded newline characters in a quoted string.
You can, however, override this default behavior in one of two ways:
- To enable newline characters in quoted strings in all sessions, set the ALLOW_NEWLINE parameter to 1 in the ONCONFIG file.
- To enable newline characters in quoted strings for the current session, execute the built-in function IFX_ALLOW_NEWLINE.
This enables newline characters in quoted strings for the current
session:
EXECUTE PROCEDURE IFX_ALLOW_NEWLINE('T');
If newline characters in quoted strings are not enabled for a session,
the following statement is invalid and returns an error:
SELECT 'The quick brown fox jumped over the old gray fence' FROM customer WHERE customer_num = 101;
If you enable newline characters in quoted strings for the session, however, the statement in the preceding example is valid and executes successfully.
For more information on the IFX_ALLOW_NEWLINE function, see IFX_ALLOW_NEWLINE Function. For more information on the ALLOW_NEWLINE parameter in the ONCONFIG file, see your HCL OneDB™ Administrator's Reference.