title: PreparedStatement with list of parameters in a IN clause
body: <p>How to set value for in clause in a preparedStatement in JDBC while executing a query.</p>
  
  <p>Example:</p>
  
  <pre><code>connection.prepareStatement("Select * from test where field in (?)");
  </code></pre>
  
  <p>If this in-clause can hold multiple values how can I do it. Sometimes I know the list of parameters beforehand or sometimes I don't know beforehand. How to handle this case?</p>