This article talks about the expressions which can be used while writing data security conditions at the metadata level of Helical Insight BI application. Expressions are the statement used for writing conditionIf and groovy code.
Operators :
Operator Name | Operator id | Sign |
---|---|---|
Less Than | lt / LT | < |
Greater Than | gt / GT | > |
Less Than Equal to | le / LE | <= |
Equal to | eq / EQ | == |
Greater Equal | ge / GE | >= |
Not Equal | ne / NE | != |
Divisor | div / DIV | / |
Modulus | mod / MOD | % |
Not | not / NOT | ! |
AND | AND | && |
TRUE | true / TRUE | |
FALSE | false / FALSE |
User Based Expressions :
Expression | Sample Value |
---|---|
${user} | 'hdiadmin' |
${user}.name | 'hdiadmin' |
${user}.id | 1 |
${user}.enabled | TRUE |
${user}.email | 'admin@abctravel.com' |
Role Based Expressions :
Expression | Sample Value |
---|---|
${role} | 'ROLE_ADMIN','ROLE_USER','ROLE_ANO' |
${role}.name | 'ROLE_ADMIN','ROLE_USER','ROLE_ANO' |
${role[0].name} | 'ROLE_ADMIN' |
${role[4].name} | ${role[4].name} |
${role}.id | 1,2,3 |
${role[0].id} | 1 |
${role[1].id} | 2 |
${role[2].id} | 3 |
${role[4].id} | ${role[4].id} |
check("${role}","ROLE_ADMIN") | true/false |
check("${role}","ROLE_ADMIN,ROLE_ANO") | true/false |
Profile Based Expressions :
Expression | Sample Value |
---|---|
${profile[0].value} | 'REGIONA','REGIONB','REGIONC' |
${profile[1].value} | 'SECTIONX','SECTIONY','SECTIONZ' |
${profile[0].id} | 1 |
${profile[1].id} | 2 |
${profile[0].name} | 'SECTION' |
${profile[1].name} | 'SUBSECTION' |
${profile['SECTION']} | 'REGIONA','REGIONB','REGIONC' |
${profile['SUBSECTION']} | 'SECTIONX','SECTIONY','SECTIONZ' |
check("${profile}","SECTION,SUBSECTION") | true/false |
Organization Based Expressions :
Expression | Sample Value |
---|---|
${org} | ABCtravel |
${org}.name | ABCtravel |
${org}.id | 1 |
For Queries, you can post on our Forum