PreparedStatement stmt = null;
try {
stmt = conn.prepareStatement("insert into permission values(?,?,?,?)");
int n = _permissions.size();
for(int i=0; i<n; i++) {
stmt.clearParameters();
stmt.setInt(1, _id);
Permission perm = (Permission)_permissions.get(i);
stmt.setString(2, perm.getClass().getName());
stmt.setString(3, perm.getName());
stmt.setString(4, perm.getActions());