Re: Quotes and spaces - Mailing list pgsql-sql

From Josh Berkus
Subject Re: Quotes and spaces
Date
Msg-id web-142849@davinci.ethosmedia.com
Whole thread Raw
In response to Quotes and spaces  (Oleg Lebedev <olebedev@waterford.org>)
List pgsql-sql
Oleg,

I'm assuming that this is just a hypothetical example, as the below is
far from the fastest way to get something as simple as a name.

> BEGIN
>     query := ''SELECT first_name || '''' '''' || last_name FROM
> user'';
>     EXECUTE query;
> ...
> END;
> ...

I'm pretty sure your quotes are correct.  However, I believe "query" is
a reserved word.  Try using a different variable name.

-Josh

______AGLIO DATABASE SOLUTIONS___________________________
                                       Josh Berkus
  Complete information technology      josh@agliodbs.com
   and data management solutions       (415) 565-7293
  for law firms, small businesses        fax 621-2533
    and non-profit organizations.      San Francisco

Attachment

pgsql-sql by date:

Previous
From: Oleg Lebedev
Date:
Subject: Quotes and spaces
Next
From: Stephan Szabo
Date:
Subject: Re: Quotes and spaces