Matthew Peter wrote:
> That doesn't seem to work with digits
>
> SELECT substring('12.00.00.34' FROM $$((\d+)\.\2)$$);
> or
> SELECT substring('12.00.00.34' FROM $$((\w+)\.\2)$$);
>
> but works with strings
>
> SELECT substring('abc.foo.foo.xyz' FROM
> $$((\w+)\.\2)$$);
>
> What I basically want to do is have a slice function
> like Python, where I can slice out items from a \s, \.
> or \n\n separated list.
You could always just write it in pl/python...
--
Peter Fein pfein@pobox.com 773-575-0694
Basically, if you're not a utopianist, you're a schmuck. -J. Feldman