| От | A. Sasaki |
|---|---|
| Тема | Re: Regular Expressions |
| Дата | |
| Msg-id | 1D0900B9-EE3F-4960-8762-B7CE6D4D59EE@gmail.com обсуждение |
| Ответ на | Regular Expressions ("Mark Williams" <markwillimas@gmail.com>) |
| Список | pgsql-sql |
‘(*\mtext1\M*\mtext2\M)|(*\mtext2\M*\mtext1\M)’
If I wanted to search for whole words in a field I would use something like:
Select * from mytable where myfield ~* ‘(\mtext1\M) | (\mtext2\M)’
This would find all instances of myfield containing either “text1” or “text2”.
I can’t figure out how to search myfield for all instances which contain “text1” AND “text2”.
In other words | is the OR operator. What is the AND operator. Tried + and whilst that executes, it doesn’t return matching fields.
Thanks
Mark
__
В списке pgsql-sql по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера