I have 2 json's where I need to compare and get the matching value, I am using the below way in java where the boolean condition works fine and returns true after the comparison but unable to get the value from getString, Receiving the error message "
the boolean condition works fine and returns the value as true
So i converted the to a JsonObject and resolved the original issue stated in this issue by following the below step,