I want to execute a query like select ID from "xyz_DB". "test" where the user is in ('a', 'b')
therefore the corresponding code is similar to
String s="(";
for(String user:selUsers){
s+= " ' " + user + " ', ";
}
s+=")";
Select an ID from the test, where userId is in s;
The following code forms the value of s as ('a', 'b',) I want to remove the comma after the end of the array, how to do it?
source
share