Uploaded image for project: 'Teiid'
  1. Teiid
  2. TEIID-2695

Unable to use CASE statement in Select

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Do
    • Icon: Major Major
    • None
    • 8.4.1
    • Query Engine
    • None

      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:

      1. A roles.properties file for use with the UsersRolesLoginModule
      2. username=role1,role2
        portfolio=superuser
        viewonly=readonly
        user=user,prices

            rhn-engineering-shawkins Steven Hawkins
            van.halbert Van Halbert (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: