Re: PQescapeBytea v 7.2.3 BUG? - Mailing list pgsql-hackers

From Joe Conway
Subject Re: PQescapeBytea v 7.2.3 BUG?
Date
Msg-id 3DCFDE26.3040705@joeconway.com
Whole thread Raw
In response to PQescapeBytea v 7.2.3 BUG?  (Reid Thompson <reid.thompson@ateb.com>)
List pgsql-hackers
Reid Thompson wrote:
> should
[...snip...]
> result in the following output?
> 
> char[0] is [\]
> char[1] is [\]
> char[2] is [\]
> char[3] is [\]
> esclen is [5]
> buffer2Ptr is [\\\\]
> 
> OR should it result in
> char[0] is [\]
> char[1] is [\]
> esclen is [3]
> buffer2Ptr is [\\]

It should result in the former:

test=# select '\\\\'::bytea as string, length('\\\\'::bytea) as length; string | length
--------+-------- \\     |      1
(1 row)


HTH,

Joe



pgsql-hackers by date:

Previous
From: Dennis Björklund
Date:
Subject: Re: Implicit coercions, choosing types for constants, etc
Next
From: Tom Lane
Date:
Subject: Re: Implicit coercions, choosing types for constants, etc (yet again)