From: Richard Huxton <dev@archonet.com>
To: sbiswas@cisco.com
To: pgsql-sql@postgresql.org
Subject: Re: FW: Function
Date: Tue, 17 Feb 2004 19:26:35 +0000
Message-ID: <200402171926.35935.dev@archonet.com> (raw)
In-Reply-To: <00e601c3f564$2dca6740$2a154d0a@apac.cisco.com>
References: <00e601c3f564$2dca6740$2a154d0a@apac.cisco.com>
On Tuesday 17 February 2004 14:41, Sumita Biswas (sbiswas) wrote:
> Is there nothing like SET NOCOUNT ON; in plpgsql
What is this supposed to do for you?
> Is there any option like SET ANSI_NULLS ON in plpgsql.
What is this supposed to do for you too?
> Do we append # before the temp table names in plpgsql, like we do for
> MSSQL ? In case no how do we create a temp table in a function in plsql?
The thing to remember with plpgsql is that it's compiled (unlike say plTcl).
This means that it translates table-names etc. into oids. So what you have to
be careful of is referring to a temporary table that is created, destroyed an
re-created (because it's oid will change).
The solution is to use the EXECUTE command to build a dynamic query. Check the
archives for plenty of other people doing this.
--
Richard Huxton
Archonet Ltd
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: dev@archonet.com, sbiswas@cisco.com
Subject: Re: FW: Function
In-Reply-To: <200402171926.35935.dev@archonet.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox