I want to remove "" from the below string, and for that I am using
String orderDetailsDb = "[{\"productId\":\"2814ff15-2fcf-4dc8-bf90-032e77a73e6b \",\"productName\":\"Garlic Oil 30 Capsules\",\"quantity\":6,\"price\":63.06,\"discount\":0,\"discountedPrice\":63.06,\"rowPrice\":\"\",\"gtinCode\":\"9324917000603\",\"accountNumber\":\"50138\",\"isPromo\":\"\"}]"
orderDetailsDb.replaceAll("\\", "");
but this is throwing
java.util.regex.PatternSyntaxException: Unexpected internal error near index 1
\
^
at java.util.regex.Pattern.error(Unknown Source)
at java.util.regex.Pattern.compile(Unknown Source)
at java.util.regex.Pattern.<init>(Unknown Source)
at java.util.regex.Pattern.compile(Unknown Source)
"\\"doesn't represent a valid Java regex.