Here you can find the source of setValues(PreparedStatement statement, Object[] values)
public static void setValues(PreparedStatement statement, Object[] values) throws SQLException
//package com.java2s; //License from project: Apache License import java.sql.PreparedStatement; import java.sql.SQLException; public class Main { public static void setValues(PreparedStatement statement, Object[] values) throws SQLException { for (int i = 0; i < values.length; i++) { statement.setObject(i + 1, values[i]); }/*from w w w .j a v a 2s.c om*/ } }