PostgreSQL newline character
<p>How to use <code>newline character</code> in <code>PostgreSQL</code>?</p>

<p>This is an incorrect script from my experiment:</p>

<pre><code>select 'test line 1'||'\n'||'test line 2';
</code></pre>

<p>I want the <code>sql editor</code> display this result from my script above:</p>

<pre><code>test line 1
test line 2
</code></pre>

<p>But unfortunately I just get this result from my script when I run it in sql editor:</p>

<pre><code>test line 1 test line 2
</code></pre>