Does string a begin with string b?

Поиск
Список
Период
Сортировка
От Robert James
Тема Does string a begin with string b?
Дата
Msg-id CAGYyBghJpTmmJnhgEdaYNVu+u4qpuiZCQqo6Pd15ob+u_Fx=QA@mail.gmail.com
обсуждение исходный текст
Ответы Re: Does string a begin with string b?  (Jeff Janes <jeff.janes@gmail.com>)
Список pgsql-general
What's the best way to check if string a begins with string b?

Both a and b are coming from fields in a table.

Requirements:

* Either a or b might have special chars (such as '%') in them which
should NOT do anything special - they're just plain strings, not
regular expressions.
* a and b can be of arbitrary length (no fixed limits)
* Ideally, I'd like it to be transparent to the query engine, so that
it can use indexes.  If both a and b are indexed, it's possible in
theory to use the index to do most of the work - but I can't come up
with a query that makes use of it.


В списке pgsql-general по дате отправления:

Предыдущее
От: Robert James
Дата:
Сообщение: Using an index to materialize a function
Следующее
От: John R Pierce
Дата:
Сообщение: Re: need help