Re: Using regexp_matches in the WHERE clause
От | spulatkan |
---|---|
Тема | Re: Using regexp_matches in the WHERE clause |
Дата | |
Msg-id | 1377781964520-5768923.post@n5.nabble.com обсуждение исходный текст |
Ответ на | Re: Using regexp_matches in the WHERE clause (David Johnston <polobo@yahoo.com>) |
Ответы |
Re: Using regexp_matches in the WHERE clause
|
Список | pgsql-sql |
I noticed that regexp_matches already returns the rows which matches the regular expression now when I make a full table select query but if I make a search with regexp_matches, it only returns rows that matches regular expression on pgadmin the column type is shown as text[] thus I also do not understand why array_length on where condition does not work for this. But maybe as it was pointed out, the return type is setof text[], that the result could have been like this (one row of data may result in multiple rows) If you have a regular expression that may end in one or more elements in the text[] then you may use inner query ps: last query is pointless as it will return 2 elements for each row (that matches the regular expression), but there may be a regular expression that may return one or more elements for each row -- View this message in context: http://postgresql.1045698.n5.nabble.com/Using-regexp-matches-in-the-WHERE-clause-tp5733684p5768923.html Sent from the PostgreSQL - sql mailing list archive at Nabble.com.
В списке pgsql-sql по дате отправления: