Skip site navigation (1) Skip section navigation (2)

Re: help with dynamic table name

From: Michael Fuhr <mike(at)fuhr(dot)org>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Jasbinder Singh Bali <jsbali(at)gmail(dot)com>, Peter Schonefeld <peter(dot)schonefeld(at)gmail(dot)com>, pgsql-novice(at)postgresql(dot)org
Subject: Re: help with dynamic table name
Date: 2007-03-06 06:19:08
Message-ID: 20070306061908.GA57364@winnie.fuhr.org (view raw or flat)
Thread:
Lists: pgsql-novice
On Mon, Mar 05, 2007 at 11:48:49PM -0500, Tom Lane wrote:
> but in this particular case there's no point in double-quoting those
> target-column names; it'd be the same to write
> 
>   sql := 'INSERT INTO '+ $3 +' (id,body) VALUES ('+ $1 +','+ $2 +')';

And shouldn't the + operators be || ?  I'm not seeing + defined for
any character types.

-- 
Michael Fuhr

In response to

pgsql-novice by date

Next:From: LukasDate: 2007-03-08 20:02:07
Subject: Pg_dump and bytaA
Previous:From: Tom LaneDate: 2007-03-06 05:36:24
Subject: Re: help with dynamic table name

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group