I have a line like this:
test_0001_suiteid_111_leavepolicy_employee
When I split this in java using a regex like:
_(?=.*_)
It shows how it looks:
test
0001
suiteid
111
leavepolicy_employee
But if I use this line:
test_0001_suiteid_111_leavepolicy
It shows how it looks:
test
0001
suiteid
111_leavepolicy
Could you explain why this is happening. I want the result to be the same as the first output using a regular regular expression.
source
share