Re: add some word in select

From: Stephen Powell <stephen_powell(at)optusnet(dot)com(dot)au>
To: pgsql-odbc(at)postgresql(dot)org
Subject: Re: add some word in select
Date: 2003-12-24 03:50:30
Message-ID: ur7yuq3g9.fsf@privacy.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-odbc

On Wed, 17 Dec 2003, ricky(at)babonmultimedia(dot)com wrote:

> hello, i have sql "select name from user" then row result "John"
> come up. is it posible that the result produce "HELLO John" .
> there's word "Hello" before the name

Use the concatenation operator '||'.

select 'Hello ' || name from user where name = 'John';

You should probably download a copy of the user manual from
<http://www.postgresql.org/docs/> . It describes many of the functions
and operators that are available.

--
Stephen Powell

In response to

Browse pgsql-odbc by date

  From Date Subject
Next Message Jean Huveneers 2003-12-24 06:31:50 Re: Hiroshi leaves the psqlodc driver ?
Previous Message freeman 2003-12-24 03:36:36 StatementHandle will be free automatically after you excute a update (delete) query that return 0 row affect.