0 votes

Is there a way to find “A or B or C or D” in PT using regex? If A, B, C and D are single characters we can put them between square brackets, but what if A, B, C and D are longer strings? PT has the function “multiple words” but this only has the option to combine two words “A or B”.

One option is: first find two words, then find the other two and “Add to list”. However, this will give less hits than the total number of occurrences: it does not give an additional hit if the different words occur in the same verse.

The case in point: I want to find all occurrences of or huú or ulu or ulú (all whole words).

Find or huú: 265 hits.

Find ulu or ulú: 76 hits.

Total: 341 hits.

Find or huú, then ulu or ulú “add to list”: 330 hits. This means that when browsing through this list, one may overlook occurrences when one of ulu/ulú and one of hū/huú occur in the same verse.

Hence my question: can this search be done with RegEx?

Paulus+Kieviet

Paratext by (493 points)
reshown

1 Answer

0 votes

Sorry, I just found out that the vertical bar | is used for alternation.

(Still, not quite sure why “regex:(hū|huú|ulu|ulú)” only gives 300 results.)

Paulus+Kieviet

by (493 points)
reshown

Paulus+Kieviet - do you have the context set to “Whole word only”? Were you using that before? That is one thing that can affect the counts. In my test I do see that each individual word in the search is found - regardless of how many occur in a verse.

Related questions

Welcome to Support Bible, where you can ask questions and receive answers from other members of the community.
I appeal to you, brothers and sisters, in the name of our Lord Jesus Christ, that all of you agree with one another in what you say and that there be no divisions among you, but that you be perfectly united in mind and thought.
1 Corinthians 1:10
2,645 questions
5,394 answers
5,065 comments
1,437 users