{"id":21207,"date":"2022-12-19T11:52:08","date_gmt":"2022-12-19T10:52:08","guid":{"rendered":"https:\/\/help.openbee.com\/open-bee-scan-capture\/knowledge-base\/how-to-guides\/useful-regex-examples\/"},"modified":"2026-05-13T09:36:35","modified_gmt":"2026-05-13T07:36:35","slug":"useful-regex-examples","status":"publish","type":"page","link":"https:\/\/help.openbee.com\/en\/open-bee-scan-capture\/knowledge-base\/how-to-guides\/useful-regex-examples\/","title":{"rendered":"Useful Regex &#8211; Examples"},"content":{"rendered":"\n<p>Retrieve a name from a customer (ignore special characters of type *.-+\/)<\/p>\n\n<p><code>((\\p{L}.?\\s?){3,}\\d{0,}) <\/code><\/p>\n\n<p>Find a word only if it is followed by a question mark but without taking the question mark<\/p>\n\n<p><code>(^|\\s)[a-zA-Z]+(?=\\?)<\/code><\/p>\n\n<p>Find a digit that is not followed by a comma or other digit<\/p>\n\n<p><code>(^|\\s)[0-9]+(?!(\\,|[0-9])) <\/code><\/p>\n\n<p>Retrieve domain names from sites<\/p>\n\n<p><code>(?&lt;=http:\\\/\\\/|https:\\\/\\\/)([a-zA-Z-0-9]+.)?([a-zA-Z0-9.-]+(?=.))<\/code><\/p>\n\n<p>5 or 6 digit number that starts with &#8220;000&#8221;<\/p>\n\n<p><code>((^|\\s)000[0-9]{2,3}($|\\s))<\/code><\/p>\n\n<p>Retrieve a phone number (Fr)<\/p>\n\n<p><code>(((+33|0)[0-9][\\s.-]?)([0-9]{2}[\\s.-]?){4})<\/code><\/p>\n\n<p>Retrieve an email<\/p>\n\n<p><code>([a-z]+.[a-z]+[0-9]{1,3}@[a-z]+.[a-z]+)<\/code><\/p>\n\n<p>Recover a rate<\/p>\n\n<p><code>([0-9]+[.,][0-9]+\\s?%)<\/code><\/p>\n\n<p>Retrieve a Postal Code (Fr)<\/p>\n\n<p><code>(\\s[0-9]{5}\\s)<\/code><\/p>\n\n<p>Find a number that is not preceded by &#8220;Order&#8221; or &#8220;Cde&#8221;<\/p>\n\n<p><code>((?&lt;!Commande\\s|Cde\\s))[0-9]+ <\/code><\/p>\n\n<p>Capture a decimal amount with 2 digits after the decimal point<\/p>\n\n<p><code>[0-9]+[,.][0-9]{2}<\/code><\/p>\n\n<p>Retrieve an invoice number in the form: FF-xxxxx or FC-xxxxx (Where x is a number)<\/p>\n\n<p><code>(FF|FC)-[0-9]{5} <\/code><\/p>\n\n<p>Retrieve the employee&#8217;s first and last name without (Mr.,Mrs,Miss &#8230;)<\/p>\n\n<p><code>(?&lt;=(M|Mme|Mlle)(\\s*)).+<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Retrieve a name from a customer (ignore special characters of type *.-+\/) ((\\p{L}.?\\s?){3,}\\d{0,}) Find a word only if it is followed by a question mark but without taking the question mark (^|\\s)[a-zA-Z]+(?=\\?) Find a digit that is not followed by a comma or other digit (^|\\s)[0-9]+(?!(\\,|[0-9])) Retrieve domain names from sites (?&lt;=http:\\\/\\\/|https:\\\/\\\/)([a-zA-Z-0-9]+.)?([a-zA-Z0-9.-]+(?=.)) 5 or 6 [&hellip;]<\/p>\n","protected":false},"author":158,"featured_media":0,"parent":21191,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-21207","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/pages\/21207","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/users\/158"}],"replies":[{"embeddable":true,"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/comments?post=21207"}],"version-history":[{"count":1,"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/pages\/21207\/revisions"}],"predecessor-version":[{"id":21208,"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/pages\/21207\/revisions\/21208"}],"up":[{"embeddable":true,"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/pages\/21191"}],"wp:attachment":[{"href":"https:\/\/help.openbee.com\/en\/wp-json\/wp\/v2\/media?parent=21207"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}