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

Re: ecpg 'set' failure using host vars

From: Michael Meskes <meskes(at)postgresql(dot)org>
To: Bosco Rama <postgres(at)boscorama(dot)com>
Cc: pgsql-interfaces(at)postgresql(dot)org,PostgreSQL Hacker <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: ecpg 'set' failure using host vars
Date: 2008-08-16 08:31:56
Message-ID: 20080816083156.GA26567@feivel.credativ.de (view raw or flat)
Thread:
Lists: pgsql-hackerspgsql-interfaces
On Fri, Aug 15, 2008 at 08:47:49PM -0700, Bosco Rama wrote:
> [22245]: ecpg_execute line 13256: QUERY: set search_path to  $1  with 1 parameter on connection ecpgconn
> [22245]: ecpg_execute line 13256: using PQexecParams
> [22245]: free_params line 13256: parameter 1 = myschema
> [22245]: ecpg_check_PQresult line 13256: Error: ERROR:  syntax error at or near "$1"
> LINE 1: set search_path to  $1

Without checking the sources it seems as if PQexecParams is not able to handle a parameter in a set command. Can anyone confirm this?

Michael
-- 
Michael Meskes
Email: Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org)
ICQ: 179140304, AIM/Yahoo: michaelmeskes, Jabber: meskes(at)jabber(dot)org
Go VfL Borussia! Go SF 49ers! Use Debian GNU/Linux! Use PostgreSQL!

In response to

Responses

pgsql-hackers by date

Next:From: Magnus HaganderDate: 2008-08-16 12:45:10
Subject: [Fwd: [COMMITTERS] pgsql: probes.h is generated from probes.d, not pg_trace.d.]
Previous:From: Pavel StehuleDate: 2008-08-16 06:44:15
Subject: Re: proposal sql: labeled function params

pgsql-interfaces by date

Next:From: Tom LaneDate: 2008-08-16 16:01:00
Subject: Re: ecpg 'set' failure using host vars
Previous:From: Bosco RamaDate: 2008-08-16 03:47:49
Subject: ecpg 'set' failure using host vars

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