Re: Junk queries with variables?

From: Michael Fuhr <mike(at)fuhr(dot)org>
To: Steve - DND <postgres(at)digitalnothing(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Junk queries with variables?
Date: 2005-02-24 17:15:32
Message-ID: 20050224171531.GA53540@winnie.fuhr.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Thu, Feb 24, 2005 at 10:04:50AM -0700, Steve - DND wrote:

> > \set name '\'Some Name\''
> > SELECT * FROM foo WHERE name = :name;
>
> Whenever I try the above I get an error at the backslash. Do I need to
> create a different language for this? Right now I only have plpgsql
> available.

Did you try it in psql? As I mentioned, \set is a psql (client side)
command.

http://www.postgresql.org/docs/8.0/static/app-psql.html

--
Michael Fuhr
http://www.fuhr.org/~mfuhr/

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Steve Valaitis 2005-02-24 17:15:43 Re: Junk queries with variables?
Previous Message Steve - DND 2005-02-24 17:11:04 Re: Junk queries with variables?