Skip to main content
Announcements
Accelerate Your Success: Fuel your data and AI journey with the right services, delivered by our experts. Learn More
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Condition in cMessageRouter

My JSON inside the Body looks like this

 

{
	"contract_number": "ES-IVE-2017/1_C",
	"delivery_year": "2017",
	"internal_model_calculation_id": "10",
	"operation": "delete"
}

And it goes through the cMessageRouter. I would like the router to let through the message that contains internal internal_model_calculation_id and operation = 'delete'.

How can I create the JSONPath to implement this condition?

Curently this is what I thought it will work, but it doesn't:

"$[?({$.operation} == 'delete' && @.internal_model_calculation_id)]"

 

Labels (3)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Hi,

 

Could you try with:

"$[?(@.operation=='delete' && @.internal_model_calculation_id)]"

 

Eric

View solution in original post

1 Reply
Anonymous
Not applicable
Author

Hi,

 

Could you try with:

"$[?(@.operation=='delete' && @.internal_model_calculation_id)]"

 

Eric