Re: plpython issue with Win64 (PG 9.2) - Mailing list pgsql-hackers

From Asif Naeem
Subject Re: plpython issue with Win64 (PG 9.2)
Date
Msg-id CACDUQd-uTq3r1o_K13HDAJ1GhORqtOdFOau1Z4Of2YH6oa-9Mw@mail.gmail.com
Whole thread Raw
In response to Re: plpython issue with Win64 (PG 9.2)  (Jan Urbański <wulczer@wulczer.org>)
Responses Re: plpython issue with Win64 (PG 9.2)
List pgsql-hackers

Patch attached. Asif, could you try a few things on a CP1252 database? 
First verify if your original test case now works and then try this:


I have test the patch on Win64. postgres server is working fine now for WIN1252. Thanks.
 
create function enctest() returns text as $$
  return b'tr\xc3\xb3spido'.decode('utf-8')
$$ language plpython3u;

select enctest(), encode(convert_to(enctest(), 'utf-8'), 'hex');

create function enctest() returns text as $$
  return b'tr\xc3\xb3spido'.decode('utf-8')
$$ language plpython3u;
select enctest(), encode(convert_to(enctest(), 'utf-8'), 'hex');
 enctest  |       encode
----------+--------------------
 tróspido | 7472c3b3737069646f
(1 row) 

Please do let me know If you have any other query. Thanks.

Best Regards,
Muhammad Asif Naeem 

pgsql-hackers by date:

Previous
From: Boszormenyi Zoltan
Date:
Subject: Re: [PATCH] lock_timeout and common SIGALRM framework
Next
From: Jan Urbański
Date:
Subject: Re: plpython issue with Win64 (PG 9.2)