cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Split by Transformation Regex not working for multiple groups

ahanchat
Guide

I want to split the Purepath based on multiple values from the value of the parameter.

To give you an example, the parameter value is

{Category=IS, publication_name=COL1, bundleVersion=2.2, bundleType=Corsica, Contexts=NPF0000000034, paramsList=site_groups, comment=COL1}

Transformation Regex is

.(?:publication_name=|Contexts=)([^,]*)

In this case, I want the value of "publication_name" and "Contexts" but I am only getting value of

"publication_name".

Could you please tell me why isn't it capturing both the values?

Thanks

Anirudha

2 REPLIES 2

asad_ali
Advisor

To get what you are looking for, create two measures. One measure would split on publication_name and other would split on Contexts. Then use both the metrics to split the BT. You won't be able to split on both using one measure.

The regex you are using is incorrect.

Here is regular expression you can try:

publication_name=([^,]*?),.*comment=([^,]*?)}

Add this to Transformation Regex and split by the measure.

Tested at: https://regex101.com/

Let me know any further help with regex.