Re: [HACKERS] \xDD patch for 7.5devel

2003-11-05 Thread Jason Godden
> #define HEXVALUE(c) \ > (((c) >= '0' && (c) <= '9') ? ((c) - '0') : \ >(((c) >= 'A' && (c) <= 'F') ? ((c) - 'A' + 10) : \ > ((c) - 'a' + 10))) > > 3. The third level would be to get rid of the assumption that letters > are contiguous, which would probably require making a lo

Re: [HACKERS] \xDD patch for 7.5devel

2003-11-05 Thread Jason Godden
On Thu, 6 Nov 2003 06:25 am, Markus Bertheau wrote: > Ð ÐÑÐ, 05.11.2003, Ð 16:25, Tom Lane ÐÐÑÐÑ: > > > +#define HEXVALUE(c) (((c)>='a') ? ((c)-87) : (((c)>='A') ? ((c)-55) : > > > ((c)-'0'))) > > > > This seems excessively dependent on the assumption that the character > > set is ASCII. Why have

[HACKERS] \xDD patch for 7.5devel

2003-11-05 Thread Jason Godden
Hi all, This is my first patch for PostgreSQL against the 7.5devel cvs (please advise if this is the wrong place to post patches). This patch simply enables the \xDD (or \XDD) hexadecimal import in the copy command (im starting with the simple stuff first). I did notice that there may be a ne

[HACKERS] \xDD in COPY Statement

2003-11-04 Thread Jason Godden
Hi all, On advice from Gavin I'm finally having a look at a few bits and pieces I can do around the pg source and Gavin suggested the hex in copy statement. Researching the lists someone has provided a rudimentary patch for this late last year (http://archives.postgresql.org/pgsql-hackers/200