Jeremy Drake wrote:
> For this case see string_to_array:

That only works with fixed delimiters, and I was hoping that 
regexp_split would be an alternative with regexp delimiters.  It's 
certainly another argument that all the split functions in PostgreSQL 
should offer analogous interfaces.  There is no reason being offered 
why splitting on a fixed string should result in an array and splitting 
on a regexp should result in a table.

> The particular use case I had for this function was at a previous
> employer, and I am not sure exactly how much detail is appropriate to
> divulge.  Basically, the project was doing some text processing
> inside of postgres, and getting all of the words from a string into a
> table with some processing (excluding stopwords and so forth) as
> efficiently as possible was a big concern.

We already have tsearch for that.

Peter Eisentraut

---------------------------(end of broadcast)---------------------------
TIP 2: Don't 'kill -9' the postmaster

Reply via email to