Appian Community
Site
Search
Sign In/Register
Site
Search
User
DISCUSS
LEARN
SUCCESS
SUPPORT
Documentation
AppMarket
More
Cancel
I'm looking for ...
State
Not Answered
Replies
9 replies
Subscribers
8 subscribers
Views
3784 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
AI and Rules
I am using below expression to display First name from the list of username in g
vineeta6579
over 10 years ago
I am using below expression to display First name from the list of username in grid text column component. I am getting " Error evaluating function 'user' : com.appiancorp.suiteapi.common.exceptions.InvalidUserException: [InvalidUserException]" . All the use are active user which i trying to populate on the grid.
Code:-
a!gridTextColumn(label:"First Name",field:"",data:fn!apply(FMS_CI_getFirstName(_) ,local!getUniqueList))
where FMS_CI_getFirstName
=user(ri!user,"firstName")
OriginalPostID-140742
OriginalPostID-140742
Discussion posts and replies are publicly visible
0
Josh
Certified Lead Developer
over 10 years ago
Maybe you have a null in your user array?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
vineeta6579
over 10 years ago
just now checked the same using below code..
=if(isnull(ri!user),"default",user(ri!user,"firstName"))
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Josh
Certified Lead Developer
over 10 years ago
As a sanity check, to make sure the users are valid you can do something like or(isnull(), not(isusernametaken())
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
vineeta6579
over 10 years ago
Any other pointer. what else can cause this!!
I have tested each username separately and it gave me expected output only
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Josh
Certified Lead Developer
over 10 years ago
So your rule works when you test each user individually but when you loop over the array you are getting an error?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
vineeta6579
over 10 years ago
Yes
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
Josh
Certified Lead Developer
over 10 years ago
Try hardcoding your local variable to a user array. If that works then there is an issue with how you are setting your local variable.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
siddharthg521
over 10 years ago
forum.appian.com/.../e-128734
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
PhilB
A Score Level 1
over 10 years ago
isnull() does not work with the user object; try isnull(tostring(<user>))
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel