Good Morning
Is there any reason why this formula doesn't work for the update mode
if(lookup(USEREMAIL(),Users,Email,Store)=Admin,"ALL_CHANGES","ADDS_AND_UPDATES")
I use this lookup on various parts of the app and it works fine there. when logged in as admin the delete button appears and when logged in as anyone else it doesn't, however when I press the delete button I get this error
Unable to delete row from table 'Deli Items'. โ Table 'Deli Items' does not allow this operation. Expression result: 'ADDS_AND_UPDATES'. Expression Trace: {"key": "IF((ANY(SELECT(Users[Store],([Email] = USEREMAIL()))) = \"Admin\"),\"ALL_CHANGES\",\"ADDS_AND_UPDATES\")","result": "ADDS_AND_UPDATES","values": []}
If I just use an email instead of the lookup it works fine but Admins will be added from time to time so don't really want to have to remember to update this formula
Can anyone shed some light on this for me?
Many thanks
Jason
Solved! Go to Solution.
Use a formula like
IF(
IN(USEREMAIL(),SELECT(Users[Email],[Store]="Admin")),
"ALL_CHANGES",
"ADDS_AND_UPDATES"
)
so the app will read the whole table. Then it's not a row related anymore.
Use a formula like
IF(
IN(USEREMAIL(),SELECT(Users[Email],[Store]="Admin")),
"ALL_CHANGES",
"ADDS_AND_UPDATES"
)
so the app will read the whole table. Then it's not a row related anymore.
Really appreciate your quick response
Works a treat, thank you very much for your help ๐
You're welcome!
User | Count |
---|---|
18 | |
9 | |
8 | |
6 | |
5 |