On this page
Use case
In this use case we will explain how to configure a Logical validator in a way that prevents issues from being created if their description has less than 100 characters without taking into account special characters and spaces.
Configuration
Add the Logical validator to the Create workflow transition.
Expression
Add the following expression:
length(replaceAll(%{issue.description}, "[^a-zA-Z_0-9]", "")) >= 100
If you need to count the spaces, you can use the following expression instead:
length(replaceAll(%{issue.description}, "[^a-zA-Z_0-9\\s]", "")) >= 100
Error message
Add an error message as the following one.
The issue description must include more than 100 characters.
Related use cases
If you still have questions, feel free to refer to our support team.