| From: | Michael Fuhr <mike(at)fuhr(dot)org> |
|---|---|
| To: | Tjibbe Rijpma <tjibbe(at)hotmail(dot)com> |
| Cc: | pgsql-novice(at)postgresql(dot)org |
| Subject: | Re: escape_string_warning doesn't work |
| Date: | 2006-03-10 18:07:27 |
| Message-ID: | 20060310180726.GA16794@winnie.fuhr.org |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-novice |
On Fri, Mar 10, 2006 at 06:24:59PM +0100, Tjibbe Rijpma wrote:
> I tried the option escape_string_warning, but why it doesn't get a warning
> with the following code:
>
> SET escape_string_warning TO on;
> CREATE DOMAIN email AS character varying(50) CHECK (((VALUE)::text ~
> '^[a-z0-9]+([_\\.-][a-z0-9]+)*@([a-z0-9]+([.-][a-z0-9]+)*)+\\.[a-z]{2,}$'::t
> ext));
I get the warning here in 8.1.3.
test=> SET escape_string_warning TO on;
SET
test=> CREATE DOMAIN email AS ... [same as above]
WARNING: nonstandard use of \\ in a string literal at character 70
HINT: Use the escape string syntax for backslashes, e.g., E'\\'.
CREATE DOMAIN
What client are you using? Version of PostgreSQL? What's your
client_min_messages setting?
--
Michael Fuhr
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Miguel | 2006-03-11 12:20:36 | Multiple insertion |
| Previous Message | Tjibbe Rijpma | 2006-03-10 17:24:59 | escape_string_warning doesn't work |