RegEx (regular expression) patterns are a standard type of coding used to match text.
In DocBoss, you can use RegEx to parse card metadata from the file names when using the Bulk Processing and Create Cards and Match features.
Formatting patterns
Common examples
- </^[^_]*/> – take first part before first “_” for ex 123_456_789
- </^(.*)_/> – takes the first part before the last “_” for ex 123_456_789
- </[^_]*$/> – take last part, for ex 1_23_45_67
- </_(.*)_/> – take the middle, for ex 1_23_45_67
- </.*/> – takes all text (file name)
Using RegEx patterns for doc no. (see article: Create Cards and Match):
It is not recommended to include symbols in the doc no. that are also used separately in the file name. To create the doc no., the underscore “_” in the RegEx patterns above can be replaced with another symbol (e.g., a dash “-“).
Include plain text
- To use the entire file name (without the extension) in a RegEx field, enter only the following text: /.*/
- To output plain text at the beginning of the value, use the following format: YourText</.*/>
- To output plain text at the beginning of the value, use the following format: </.*/>YourText
- To output plain text in the middle of the value, use the following format: </.*/>YourText</.*/>
Advanced
- There is lots of information online about formatting regular expressions. For example, see this guide from MDN Web Docs.