The regex: "bi bil" (without the quotation marks) matches bi and bil separated with a space (blank);
"bi\sbil" would match bi and bil separated with a whitespace
Subject:
Comment:
The contents of this post will automatically be included in the ticket generated. Please add any additional comments or explanation (optional)
(?!bi bil)bi.*bil
For such situations I have just published a book:
"Practical Usage of Regular Expressions; An introduction to regexes for translators"
that provides many useful examples as well as an easy introduction to regexes, not only for translators.
Subject:
Comment:
The contents of this post will automatically be included in the ticket generated. Please add any additional comments or explanation (optional)
On its basis I am testing this code: (?! bi bil\w?) bi.*bil
I have this example of text: „X naj bi na podlagi sporazuma predložilo predlog za določitev, ki naj bi bil obravnavan na seji.“
The phrase contains first „bi“ and then „bi bil“ and code gives me a match. However, there should be no match, because „bi bil“ should not be matched and „bi“ should also not be matched when standing alone without „bil“ (and not „bi bil“) following later on.
I understand that code finds a match because it takes first „bi“ and then „bil“ (from „bi bil“). But I don't want it to take „bil“ (from „bi bil“), as I want „bi bil“ to be a undivided unite that is ignored completely. Is there a way to integrate that in code?
With other words, if I take a code (?! bi bil\w?) bi.*bil. This very last bil of the code shold not bi part of „bi bil“ in text.
[Edited at 2018-04-12 19:53 GMT]
[Edited at 2018-04-12 19:54 GMT]
Subject:
Comment:
The contents of this post will automatically be included in the ticket generated. Please add any additional comments or explanation (optional)
SDL Community United Kingdom Local time: 08:59 English
Almost...
Apr 12
(?!.*bi bil\w?) bi.*bil
Subject:
Comment:
The contents of this post will automatically be included in the ticket generated. Please add any additional comments or explanation (optional)
Translate faster & easier, using a sophisticated CAT tool built by a translator / developer.
Accept jobs from clients who use SDL Trados, MemoQ, Wordfast & major CAT tools.
Download and start using CafeTran Espresso -- for free
Translation Office 3000 is an advanced accounting tool for freelance translators and small agencies. TO3000 easily and seamlessly integrates with the business life of professional freelance translators.