[SPARK-2710] check parameters by PreparedStatement