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

Re: ERROR: Invalid regular expression: parentheses ( ) not balanced

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: aklaver(at)attbi(dot)com
Cc: "Kathrine S" <skybert_ks(at)hotmail(dot)com>, pgsql-sql(at)postgresql(dot)org
Subject: Re: ERROR: Invalid regular expression: parentheses ( ) not balanced
Date: 2004-08-26 02:54:28
Message-ID: 11496.1093488868@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-sql
Adrian Klaver <aklaver(at)comcast(dot)net> writes:
> I don't know what to make of it but the problem seems to start at the lines I
> have marked 1 & 2 and involves the lo_import function. I have not used 
> lo_import and so do not know how to call it.  What I do see is that it is 
> called at 1 and a  '('  shows up to the  left of the prompt at 2 and stays 
> there indicating to me at least the parser is not happy.

No, that's just because psql has noticed that the left paren following
VALUES is unmatched.  I suppose that what Kathrine is showing us is
line-wrapped text and that the lo_import function call was actually
typed on the same line as "values(...", since there's not another psql
prompt visible there.

But in any case, the given error message could only have come from a
regex match operator (~ or ~*) that does not like the pattern operand it
was given.  Since there's no ~ operator in the given query, I have to
suppose that the problem is in something that's being invoked behind-the-
scenes, like a trigger or rule.

			regards, tom lane

In response to

pgsql-sql by date

Next:From: Scott GerhardtDate: 2004-08-26 06:23:05
Subject: Aggregate query for multiple records
Previous:From: Adrian KlaverDate: 2004-08-26 02:44:52
Subject: Re: ERROR: Invalid regular expression: parentheses ( ) not balanced

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