[
https://jira.jboss.org/jira/browse/JBPORTAL-2454?page=com.atlassian.jira....
]
Sohil Shah resolved JBPORTAL-2454.
----------------------------------
Resolution: Done
CMS identity queries with case sensitive DB fails
-------------------------------------------------
Key: JBPORTAL-2454
URL:
https://jira.jboss.org/jira/browse/JBPORTAL-2454
Project: JBoss Portal
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Portal CMS
Affects Versions: 2.7.2 Final
Environment: MS SQL Server 2005
Reporter: Magesh Kumar B
Assignee: Sohil Shah
Create a new user and login with the new user's id. We get the following exception
ERROR [org.hibernate.util.JDBCExceptionReporter] Invalid column name 'id'.
ERROR [org.jboss.portal.cms.security.AuthorizationProviderImpl]
org.jboss.portal.cms.security.AuthorizationProviderImpl@3c205c
org.hibernate.exception.SQLGrammarException: could not execute query
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:67)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.loader.Loader.doList(Loader.java:2223)
at org.hibernate.loader.Loader.listUsingQueryCache(Loader.java:2136)
at org.hibernate.loader.Loader.list(Loader.java:2096)
at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:289)
at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1695)
at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:142)
at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:152)
at
org.jboss.portal.cms.security.AuthorizationProviderImpl.findPermissionsByUser(AuthorizationProviderImpl.java:480)
at
org.jboss.portal.cms.security.AuthorizationProviderImpl.getSecurityBindings(AuthorizationProviderImpl.java:221)
at
org.jboss.portal.cms.impl.jcr.command.ACLEnforcer.getPermissions(ACLEnforcer.java:572)
This is due to the fact that hibernate mappings instructs the DB to create the table
jbp_cms_perm with column name 'ID', but
AuthorizationProviderImpl.findPermissionsByUser has a hard coded SQL query with lower
case.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira