In http://docs.oracle.com/javase/tutorial/jdbc/basics/array.html
Storing and Updating Array Objects
Use the methods PreparedStatement.setArray and PreparedStatement.setObject to pass an Array value as an input parameter to a PreparedStatement object.
The following example sets the Array object northEastRegion (created in a previous example) as the second parameter to the PreparedStatement pstmt:
PreparedStatement pstmt = con.prepareStatement(
"insert into REGIONS (region_name, zips) " + "VALUES (?, ?)");
pstmt.setString(1, "NorthEast");
pstmt.setArray(2, northEastRegion);
pstmt.executeUpdate();
Similarly, use the methods PreparedStatement.updateArray and PreparedStatement.updateObject to update a column in a table with an Array value.
Change: northEastRegion -> aArray
Storing and Updating Array Objects
Use the methods PreparedStatement.setArray and PreparedStatement.setObject to pass an Array value as an input parameter to a PreparedStatement object.
The following example sets the Array object northEastRegion (created in a previous example) as the second parameter to the PreparedStatement pstmt:
PreparedStatement pstmt = con.prepareStatement(
"insert into REGIONS (region_name, zips) " + "VALUES (?, ?)");
pstmt.setString(1, "NorthEast");
pstmt.setArray(2, northEastRegion);
pstmt.executeUpdate();
Similarly, use the methods PreparedStatement.updateArray and PreparedStatement.updateObject to update a column in a table with an Array value.
Change: northEastRegion -> aArray