pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Fuhr <mike@fuhr.org>
To: Sabin Coanda <sabin.coanda@deuromedia.ro>
Cc: pgsql-sql@postgresql.org
Subject: Re: How compare current_setting(..) ?
Date: Thu, 22 Feb 2007 04:03:54 -0700
Message-ID: <20070222110353.GA7197@winnie.fuhr.org> (raw)
In-Reply-To: <erjr2t$sdn$1@news.hub.org>
References: <erjr2t$sdn$1@news.hub.org>

On Thu, Feb 22, 2007 at 12:25:42PM +0200, Sabin Coanda wrote:
> I'd like to check that my log_line_prefix is set to '%t'.
> I suppose I can check it with the following statement:
>     SELECT current_setting( 'log_line_prefix' )
>     WHERE current_setting( 'log_line_prefix' ) != '%t'
> 
> But it returns every time a row, with '%t', even when log_line_prefix is set 
> to '%t'.
> What's wrong ?

Works here.  Might log_line_prefix have leading or trailing spaces?
What does the following return?

SELECT '<' || current_setting('log_line_prefix') || '>',
       length(current_setting('log_line_prefix'));

-- 
Michael Fuhr



view thread (3+ messages)  latest in thread

Message-ID: <20070222110353.GA7197@winnie.fuhr.org>
Permalink:  ../20070222110353.GA7197@winnie.fuhr.org/
Also on:    postgresql.org/message-id/20070222110353.GA7197@winnie.fuhr.org

 · 

reply

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: mike@fuhr.org, sabin.coanda@deuromedia.ro
  Subject: Re: How compare current_setting(..) ?
  In-Reply-To: <20070222110353.GA7197@winnie.fuhr.org>

* 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