Re: Using POSIX Regular Expressions on xml type fields gives inconsistent results
В списке pgsql-general по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: Using POSIX Regular Expressions on xml type fields gives inconsistent results |
| Дата | |
| Msg-id | 27093.1356285306@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: Using POSIX Regular Expressions on xml type fields gives inconsistent results ("David Johnston" <polobo@yahoo.com>) |
| Список | pgsql-general |
"David Johnston" <polobo@yahoo.com> writes:
>> while it might work to reverse the order in a regex, I have experienced
>> severe slowdown when the pattern comes from table data
> If it is indeed related to the custom reverse query the fact that you are
> going through an SQL wrapper to access a c-level function is inevitably
> going to degrade performance.
I believe that in most situations of interest, the SQL wrapper would get
"inlined" and thus create no significant per-row penalty. It's possible
this isn't happening in some specific case, but as you say we'd need to
see a concrete example to know one way or the other.
Another point that comes to mind is that "pattern comes from table data"
probably means "query uses a whole lot of different patterns over its
lifetime". Each different pattern is going to require regex
compilation, which is not a particularly cheap operation.
regards, tom lane
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера