pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Ross J. Reedstrom <reedstrm@rice.edu>
To: Bjørn T Johansen <bjorntj@softinn.no>
Cc: pgsql-sql@postgresql.org
Subject: Re: Strange parse error??
Date: Thu, 22 Feb 2001 17:18:06 -0600
Message-ID: <20010222171806.A28996@rice.edu> (raw)
In-Reply-To: <919338627.20010222234930@softinn.no>
References: <919338627.20010222234930@softinn.no>

On Thu, Feb 22, 2001 at 11:49:30PM +0100, Bjørn T Johansen wrote:
> I am trying to do a simple update (or at least I thought it was
> simple), but I just keep getting a parse error, saying:
> 
> Error executing query
> 
> Update "Config" Set "Wave" = 'F:\wav\BTJ.wav',"Answer" = 20,
> "Recordwav" ='F:\wav\',"CalledID" = '12345678' where "Recno" = 1
> 
> PostgreSQL error message:
> ERROR: parser: parse error at or near "12345678"

Backslashes are used for quoting, so what you're trying to do looks
something like this to the server:

Update "Config" Set "Wave" = 'F:wavBTJ.wav',"Answer" = 20,
 "Recordwav" ='F:wav\',"CalledID" = '12345678' where "Recno" = 1

You could confirm by turning up debugging on the server and check
the logs.

So, it's trying to store the string :

F:wav',"CalledID" =

(with trailing space, even) in Recordwav.

Try doubling your backslashes, as so:

 Update "Config" Set "Wave" = 'F:\\wav\\BTJ.wav',"Answer" = 20,
"Recordwav" ='F:\\wav\\',"CalledID" = '12345678' where "Recno" = 1


Ross



view thread (3+ messages)

Message-ID: <20010222171806.A28996@rice.edu>
Permalink:  ../20010222171806.A28996@rice.edu/
Also on:    postgresql.org/message-id/20010222171806.A28996@rice.edu

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-sql@postgresql.org
  Cc: reedstrm@rice.edu, bjorntj@softinn.no
  Subject: Re: Strange parse error??
  In-Reply-To: <20010222171806.A28996@rice.edu>
  References: <919338627.20010222234930@softinn.no> <20010222171806.A28996@rice.edu>

* 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