Received: from sss.pgh.pa.us (sss.pgh.pa.us [209.114.132.154]) by mail.postgresql.org (8.11.3/8.11.1) with ESMTP id f2JJ8XN09168 for ; Mon, 19 Mar 2001 14:08:33 -0500 (EST) (envelope-from tgl@sss.pgh.pa.us) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.11.1/8.11.1) with ESMTP id f2JJ8Vt20793; Mon, 19 Mar 2001 14:08:31 -0500 (EST) To: "Josh Berkus" cc: pgsql-sql@postgresql.org Subject: Re: What do I do with this error? In-reply-to: References: Comments: In-reply-to "Josh Berkus" message dated "Mon, 19 Mar 2001 11:04:13 -0800" Date: Mon, 19 Mar 2001 14:08:31 -0500 Message-ID: <20790.985028911@sss.pgh.pa.us> From: Tom Lane X-Archive-Number: 200103/365 X-Sequence-Number: 2031 "Josh Berkus" writes: > Tom, >> regression=# select 'foo' ~* ''; >> ERROR: regcomp failed with error empty (sub)expression >> >> This is correct according to the POSIX definition of regular >> expressions >> ("A (modern) RE is one or more non-empty branches ..."). > That sounds like what I'm seeing! And now that you point it out, there > is a bug in the PHP that calls this function that passes an empty string > ('') instead of a NULL. Thanks! > Any possibility that that error message could be made more informative? > (i.e. ERROR: regcomp failed due to empty string in regular expression) You're right, this isn't a very transparent message. Perhaps ERROR: Invalid regular expression (empty expression or subexpression) Comments, better wordings? regards, tom lane