How to set list of parameters on prepared statement?
There's no clean way to do this simply by setting a list on the PreparedStatement
that I know of.
Write code that constructs the SQL statement (or better replaces a single ? or similar token) with the appropriate number of questions marks (the same number as in your list) and then iterate over your list setting the parameter for each.
This question is very old, but nobody has suggested using setArray
This answer might help https://stackoverflow.com/a/10240302/573057