Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
click_on_qlik
Partner - Contributor II
Partner - Contributor II

How to insert new line in a SQL text message ?

 

Hi

In the data load editor I want to send a mail , and i want to add a \n (newline ) in the text field message,  but it does not work 

here is the code

 

SELECT status,
result
FROM SendEmail
WITH PROPERTIES (
to='$(Email)',
subject='Result monitoring',
message='The  app name is xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

NEWLINE

xxxxxxxxxxxxxxxxxxxxxxxx ',
html='true',
fromName='aaaaa',
fromEmail='bbbbbbbbbbbbbbbbbbbb',
cc='',
bcc=''
);

Labels (3)
1 Reply
Aasir
Creator III
Creator III

CHAR(13) || CHAR(10) is used to represent a new line.

SELECT status,
result
FROM SendEmail
WITH PROPERTIES (
to='$(Email)',
subject='Result monitoring',
message='The app name is xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' || CHAR(13) || CHAR(10) ||
'xxxxxxxxxxxxxxxxxxxxxxxx',
html='true',
fromName='aaaaa',
fromEmail='bbbbbbbbbbbbbbbbbbbb',
cc='',
bcc=''
);