[DOCS] Backslash Escape Sequences

2008-04-30 Thread Andy Anderson

On the list pgsql-general, I had this exchange:


Andy Anderson <[EMAIL PROTECTED]> writes:
In a test I just did, the sequence \" (backslash double-quote) is  
interpreted as just a " inside of the E'...' string constant  
expression. This is great, since PHP's addslashes() sticks them  
in along with the other stuff I really need to quote like ' and  
\. But I see that \" isn't documented in the manual in section  
4.1.2.1.  I assume this is, in fact, standard behavior for  
Postgres? (Perhaps a comprehensive table might be a good idea at  
this point in the manual.)


Tom Lane wrote:

Huh?  It says

  Any other character following a backslash is taken literally.




 Andy Anderson wrote:
Ah, slight ambiguity here. Perhaps this might best say "Any other  
character following a backslash is taken literally, and the  
backslash is removed."


In any case, here's a contribution to the manual, a short table with  
this information, in a format that might help make the subject  
clearer. Modify at will!


-- Andy




--
Sent via pgsql-docs mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-docs


Re: [DOCS] Backslash Escape Sequences

2008-04-30 Thread Alvaro Herrera
Andy Anderson wrote:

> In any case, here's a contribution to the manual, a short table with  
> this information, in a format that might help make the subject clearer. 
> Modify at will!

FWIW if you really want to make a contribution to the docs, please see
the SGML sources instead of the HTML output (which is machine-generated).

http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/doc/src/sgml/

-- 
Alvaro Herrerahttp://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

-- 
Sent via pgsql-docs mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-docs