1/please couls someone tell me where is the error: i got this message 'java.sql.SQLException: ORA-00907: missing right parenthesis '
2/my query returns a list of group_id,im i following the "grpPrivileges" correctly?
code:
public List groupUG() {
List grpPrivileges = new ArrayList();
ResultSet resultSet = null;
PreparedStatement createPreparedStatement
getDBTransaction().createPreparedStatement("" +
"select distinct ug.GROUP_ID from USER_GROUP ug\n" +
" where ug.GROUP_ID in(\n" +
"select ag.GROUP_ID\n" +
"from ACL__GROUP ag\n" +
"where ag.GROUP_ID= ug.GROUP_ID and ug.USER_ID=" + CurrentUser() +
"and ag.DOCUMENT_ID=" + getDocumentId()+"",0);
try {
resultSet = createPreparedStatement.executeQuery();
while (resultSet.next()) {
grpPrivileges.add(resultSet.getInt(1));
}
} catch (SQLException e) {
throw new JboException(e);
}
return grpPrivileges;
}