Re: [GENERAL] Request to add feature to the Position function

2017-05-11 Thread Adrian Klaver
On 05/11/2017 10:55 AM, Ron Ben wrote: any news on that? Did you ask on --hackers or file a bug report? -- Adrian Klaver adrian.kla...@aklaver.com -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription:

Re: [GENERAL] Request to add feature to the Position function

2017-03-29 Thread Adrian Klaver
On 03/29/2017 04:06 AM, Ron Ben wrote: I never expected it to be implemented now.. I understand that there are policies and priorities I tried to find a feature request chanle but there is none... This list and and/or --hackers would be that channel. I don't know how the postresql team

Re: [GENERAL] Request to add feature to the Position function

2017-03-29 Thread Ron Ben
I never expected it to be implemented now.. I understand that there are policies and priorities I tried to find a feature request chanle but there is none... I don't know how the postresql team decied what is on the "to do list" and what is not. This is a feature which I think people will find

Re: [GENERAL] Request to add feature to the Position function

2017-03-28 Thread David G. Johnston
On Tue, Mar 28, 2017 at 7:09 AM, Adrian Klaver wrote: > On 03/28/2017 12:29 AM, Ron Ben wrote: > >> Here is a refer to the stackoverflow question: >> >> http://stackoverflow.com/questions/42974822/find-sub-string- >> position-from-the-end-of-string-in-postgresql >> >>

Re: [GENERAL] Request to add feature to the Position function

2017-03-28 Thread Adrian Klaver
On 03/28/2017 12:29 AM, Ron Ben wrote: Here is a refer to the stackoverflow question: http://stackoverflow.com/questions/42974822/find-sub-string-position-from-the-end-of-string-in-postgresql it carry another example and the solution however I still think that this fuctionality should be

Re: [GENERAL] Request to add feature to the Position function

2017-03-28 Thread Ron Ben

Re: [GENERAL] Request to add feature to the Position function

2017-03-27 Thread Mark Watson
De : pgsql-general-ow...@postgresql.org [mailto:pgsql-general-ow...@postgresql.org] De la part de Ron Ben Envoyé : Monday, March 27, 2017 11:05 AM À : pgsql-general@postgresql.org Objet : [GENERAL] Request to add feature to the Position function > position(substring in string) > as

Re: [GENERAL] Request to add feature to the Position function

2017-03-27 Thread Adrian Klaver
On 03/27/2017 09:15 AM, David G. Johnston wrote: On Mon, Mar 27, 2017 at 9:03 AM, Brian Dunavant >wrote: That does not return the correct answer for the original poster's request. flpg=# ​​ select position('om' in

Re: [GENERAL] Request to add feature to the Position function

2017-03-27 Thread David G. Johnston
On Mon, Mar 27, 2017 at 9:16 AM, Adrian Klaver wrote: > On 03/27/2017 09:03 AM, Brian Dunavant wrote: > >> That does not return the correct answer for the original poster's request. >> >> flpg=# select position('om' in reverse('Tomomasaaa')); >> position >>

Re: [GENERAL] Request to add feature to the Position function

2017-03-27 Thread Brian Dunavant
Putting together Adrian Klaver's, and David Johnson's suggestions I think gets to what he was asking for: # select length('Tomomasomaa') - position(reverse('om') in reverse('Tomomasomaa')); ?column? -- 12 On Mon, Mar 27, 2017 at 12:16 PM, Adrian Klaver

Re: [GENERAL] Request to add feature to the Position function

2017-03-27 Thread Adrian Klaver
On 03/27/2017 09:03 AM, Brian Dunavant wrote: That does not return the correct answer for the original poster's request. flpg=# select position('om' in reverse('Tomomasaaa')); position -- 15 (1 row) It shows the position counting back from the end. If you want counting

Re: [GENERAL] Request to add feature to the Position function

2017-03-27 Thread David G. Johnston
On Mon, Mar 27, 2017 at 9:03 AM, Brian Dunavant wrote: > That does not return the correct answer for the original poster's request. > > flpg=# > ​​ > select position('om' in reverse('Tomomasaaa')); > position > -- >15 > (1 row) > > ​Easy oversight to

Re: [GENERAL] Request to add feature to the Position function

2017-03-27 Thread Brian Dunavant
That does not return the correct answer for the original poster's request. flpg=# select position('om' in reverse('Tomomasaaa')); position -- 15 (1 row) On Mon, Mar 27, 2017 at 11:43 AM, Adrian Klaver wrote: > On 03/27/2017 08:05 AM, Ron Ben

Re: [GENERAL] Request to add feature to the Position function

2017-03-27 Thread Adrian Klaver
On 03/27/2017 08:05 AM, Ron Ben wrote: Hi, position(substring in string) as listed here: https://www.postgresql.org/docs/9.1/static/functions-string.html locates sub string in a string. It doesn't support locateing the substring from the back. For example: position('om' in 'Tomomas') gives 2

[GENERAL] Request to add feature to the Position function

2017-03-27 Thread Ron Ben
Hi, position(substring in string) as listed here: https://www.postgresql.org/docs/9.1/static/functions-string.html locates sub string in a string.   It doesn't support locateing the substring from the back.   For example:   position('om' in 'Tomomas') gives 2   But if I want to locate the first