Re: I: [HACKERS] TODO: Allow substring/replace() to get/set bit values

2010-01-07 Thread Leonardo F
Is anybody interested? Otherwise the entry could be removed from the TODO list... Even if not, you can still submit a patch. There are a lot more users of PG than there are people who read -hackers. Ok, I'll try and submit a patch. Thank you very much. -- Sent via pgsql-hackers

Re: I: [HACKERS] TODO: Allow substring/replace() to get/set bit values

2010-01-06 Thread Leonardo F
To sum up: 1) a new function, get_bit, that calls substring 2) a new function, overlay, that replaces bits (starting at a certain position) 3) a new function, set_bit, that calls overlay That seems reasonable to me. Not sure what others think. Is anybody interested? Otherwise the

Re: I: [HACKERS] TODO: Allow substring/replace() to get/set bit values

2010-01-06 Thread Robert Haas
On Wed, Jan 6, 2010 at 1:21 PM, Leonardo F m_li...@yahoo.it wrote: To sum up: 1) a new function, get_bit, that calls substring 2) a new function, overlay, that replaces bits (starting at a certain position) 3) a new function, set_bit, that calls overlay That seems reasonable to me.  

Re: I: [HACKERS] TODO: Allow substring/replace() to get/set bit values

2010-01-05 Thread Leonardo F
You might want to search the archives (or the wiki history, or the CVS history if it's been there since before we moved the TODO list to the wiki) for discussion of why that item was added to the TODO in the first place. I read the thread:

Re: I: [HACKERS] TODO: Allow substring/replace() to get/set bit values

2010-01-05 Thread Robert Haas
On Tue, Jan 5, 2010 at 3:58 AM, Leonardo F m_li...@yahoo.it wrote: You might want to search the archives (or the wiki history, or the CVS history if it's been there since before we moved the TODO list to the wiki) for discussion of why that item was added to the TODO in the first place. I

Re: I: [HACKERS] TODO: Allow substring/replace() to get/set bit values

2010-01-05 Thread Leonardo F
As you say, there's really no point in changing the internal representation, and if you don't find replace() useful either, then why are you even working on this at all? I would like a get_bit / set_bit for bit strings, as I find them useful. get_bit could be a simple call to substring, but

Re: I: [HACKERS] TODO: Allow substring/replace() to get/set bit values

2010-01-05 Thread Robert Haas
On Tue, Jan 5, 2010 at 10:45 AM, Leonardo F m_li...@yahoo.it wrote: As you say, there's really no point in changing the internal representation, and if you don't find replace() useful either, then why are you even working on this at all? I would like a get_bit / set_bit for bit strings, as I

I: [HACKERS] TODO: Allow substring/replace() to get/set bit values

2010-01-04 Thread Leonardo F
Re-reading the docs it looks like the only thing missing is get/set_bit for bit string. Substring is already implemented for bit string, and I don't really know if replace is useful at all. (sorry if the other mail came with a different sender name) Leonardo I would like to work on

Re: I: [HACKERS] TODO: Allow substring/replace() to get/set bit values

2010-01-04 Thread Robert Haas
On Mon, Jan 4, 2010 at 5:17 AM, Leonardo F m_li...@yahoo.it wrote: Re-reading the docs it looks like the only thing missing is get/set_bit for bit string. Substring is already implemented for bit string, and I don't really know if replace is useful at all. (sorry if the other mail came