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

Re: Problem with PG_GETARG_CSTRING

From: "Brett Maton" <Brett(dot)Maton(at)simplyhealth(dot)co(dot)uk>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: <pgsql-novice(at)postgresql(dot)org>
Subject: Re: Problem with PG_GETARG_CSTRING
Date: 2007-10-12 15:49:15
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-novice
Ok, that means it's not something blindingly obvious then :-)

  I brought the code home and have tried it on one of my machines here.

  First time the function has been created so no picking the wrong .so
  Differences are that here I'm running Postgres 8.1.10-1 on Fedora Core 6

  Unfortunately when I call the function with:

  select * from bm_test('PRODAPP');

  I get the same result:

  NOTICE:  szPolicy len [1]'

  Followed by the expected list of Notices for each hostname in the servers table.
  My C is a bit rusty I'll be the first to admit but I'm really not getting where the line break is coming from.

  For info in my pg_log file it's reporting:

  NOTICE:  szPolicy len [1]'^K'

  Not sure if ^K means anything to anyone, would have expected to see ^J (10) or ^M (13)...


-----Original Message-----
From: Tom Lane [mailto:tgl(at)sss(dot)pgh(dot)pa(dot)us]
Sent: Fri 12/10/2007 16:10
To: Brett Maton
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: [NOVICE] Problem with PG_GETARG_CSTRING 
"Brett Maton" <Brett(dot)Maton(at)simplyhealth(dot)co(dot)uk> writes:
> I'm probably just being a numpty, but I can't seem to get arguments with PG=

The code looks all right as far as I can see --- I suspect procedural
error, like you aren't loading the right .so file, or changed the code
and didn't re-LOAD the .so, or something like that.

			regards, tom lane

This email, and the contents contained within, are private
and confidential between the sender and the individual(s)
to whom it is addressed.
The contents do not necessarily represent the views of Simplyhealth Group

In the event of misdirection, the recipient is prohibited from 
using, copying or disseminating it or any information contained in it.
If you have received this email in error please notify Simplyhealth
immediately by telephone on 0845 075 2020, or by email to 

Simplyhealth Group Limited is registered and incorporated in England and Wales  
as a company limited by guarantee. Its registered office is at Hambleden House, 
Waterloo Court, Andover, Hampshire, SP10 1LQ, registered no. 5445654. We 
may record or monitor telephone calls to help improve our service and protect our 

In response to


pgsql-novice by date

Next:From: John GuntherDate: 2007-10-12 15:59:13
Subject: accented characters migraine
Previous:From: John GuntherDate: 2007-10-12 15:45:12
Subject: accented characters migraine

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