Skip to content

Instantly share code, notes, and snippets.

@jb7959
Last active November 16, 2016 10:08
Show Gist options
  • Save jb7959/f8680a58a37da90de00985a81387cc8c to your computer and use it in GitHub Desktop.
Save jb7959/f8680a58a37da90de00985a81387cc8c to your computer and use it in GitHub Desktop.
This method is for Statement Object to use like a Prepared Statement.
String str = [1, 2, 3];
str = str.replaceAll("\\[", "\"").replaceAll("\\]","\"").replaceAll("\\,","\"\\,").replaceAll(" ","\"").trim();
//input : [1, 2, 3]
//output : "1","2","3"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment