[teiid-issues] [JBoss JIRA] (TEIID-2695) Unable to use CASE statement in Select
Steven Hawkins (JIRA)
jira-events at lists.jboss.org
Fri Oct 11 14:26:26 EDT 2013
[ https://issues.jboss.org/browse/TEIID-2695?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Steven Hawkins resolved TEIID-2695.
-----------------------------------
Resolution: Rejected
Had to work through the nuances of hasRole and Teiid roles.
Possible related enhancements/changes:
- optionally (given that we've had the current behavior for years) throw an exception if the role name specified does not exist rather than returning false
- add a getRoles() function/procedure to show the user roles
- have some kind of a "dynamic" vdb like approach to Teiid roles such that we do some kind of import of role names from the source - of course with our current vdb.xml approach this doesn't really jive with adding permissions, it just makes you aware of the group names.
- a hasGroup function
> Unable to use CASE statement in Select
> --------------------------------------
>
> Key: TEIID-2695
> URL: https://issues.jboss.org/browse/TEIID-2695
> Project: Teiid
> Issue Type: Bug
> Components: Query Engine
> Affects Versions: 8.4.1
> Reporter: Van Halbert
> Assignee: Steven Hawkins
> Attachments: portfolio-vdb.xml
>
>
> Trying to add a <mask> of:
> <permission>
> <resource-name>Stocks.StockPrices.Price</resource-name>
> <mask>CASE WHEN hasRole('prices') THEN Price END</mask>
> </permission>
> even tried using "= true" just to see
> but it it always returns null for Prices.
> To test it, I logged in as 'user' using CommandLog vdb and issued:
> Select VDB, CASE WHEN hasRole('prices') THEN 'Y' Else 'N' END as V from TEIID_COMMANDLOG
> and 'N' was always returned for column V.
> teiid roles file:
> # A roles.properties file for use with the UsersRolesLoginModule
> # username=role1,role2
> portfolio=superuser
> viewonly=readonly
> user=user,prices
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the teiid-issues
mailing list