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
14 replies
Subscribers
11 subscribers
Views
4746 views
Users
0 members are here
Share
More
Cancel
Related Discussions
Home
»
Discussions
»
Data and Records
In the User Profile Record Type it uses a rule: a!userRecordFacets to expose a s
mikec
over 9 years ago
In the User Profile Record Type it uses a rule: a!userRecordFacets to expose a single "Status' facet. Is it possible to add additional facets? For example, being able to add alphabetical filters (A-D,E-H, etc) would allow a user to scan user profiles that otherwise they cannot do so at this time. As I am sure with many other companies we have 100's of employees in Appian but the record only shows the first 100. If I am not sure of the user's name there is no way for me to scan for any other resources.
OriginalPostID-157596
OriginalPostID-157596
Discussion posts and replies are publicly visible
0
sikhivahans
over 9 years ago
@mikec Hi, could you please go through documentation at
forum.appian.com/.../User_Management.html
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
mikec
over 9 years ago
Thank you. Should have looked there first:-) Question for you though: the facet I would like to create is an alpha facet. I am having trouble getting the syntax correct. I have a column in my table called "lastname" I want to create a facet option similar to this:
a!facet(
name: "By Last Name",
options: {
a!facetOption(
id: 2,
name: "A - F",
filter: a!queryFilter(
field: "lastname",
operator: "starts with",
value: {"A","B","C","D","E","F"}
)
),
a!facetOption(
id: 3,
name: "G - L",
filter: a!queryfilter(
field: "lastname",
operator: "starts with",
value: {"G","H","I","J","K","L"
)
)
}
)
Not sure if this syntax works or do I need to place an index function in front of the value array? Any help would be appreciated!
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sikhivahans
over 9 years ago
@mikec No worries, May I please know what you meant by "I have a column in my table called "lastname". I guess you can only use the attributes of user in the facets as the record is sourced from the User objects in Appian instance. For instance you could use 'lastName' which is an attribute of the User object in Appian.
In order to use 'BETWEEN' operator I would like to suggest to refer section 'User Filters' at https://forum.appian.com/suite/help/7.10/Record_Design.html#User_Filters which gives an example about BETWEEN operator. We do have an illustration as well at this location.
And added to the above, your filters seems correct except one minor issue. I guess we won't be able to use '2' as id in facetOption, as the documentation at https://forum.appian.com/suite/help/7.10/User_Management.html#Add_User_Filters under section 'Add User Filters' says that 'Notice that the IDs used for the filter options in the above expression start with 3. That is because IDs 1 and 2 are already being used for the filter options for the "Status" user filter. Filter option IDs cannot be reused across multiple user filters for the same record type.'. Consider this if you are using Status filter as well.
Hope the above suggestions give you leads.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sikhivahans
over 9 years ago
@mikec Added to above, 'between' operator seems correct to me when compared to 'starts with'. That's the reason why I have suggested the documentation of 'between' illustration.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
ENOSH EZEKIEL
A Score Level 1
over 8 years ago
@mike @sikhivahans - I also have the same requirement as what Mike mentioned. To display the Users in an alphabetical order. PFB the expression which I'm using:
{
a!userRecordFacets(),
a!facet(
name: "First Names starting with",
options: {
a!facetOption(
id: 3,
name: "A - E",
filter: a!queryFilter(
field: "firstName",
operator: "BETWEEN",
value: {
"A",
"E"
}
)
),
a!facetOption(
id: 4,
name: "F - J",
filter: a!queryFilter(
field: "firstName",
operator: "BETWEEN",
value: {
"F",
"J"
}
)
)
}
)
}
I get an error when I click on the list view item saying HTTP code =404. Server logs say that an error occured while retrieving the data for Users.
Can you pls suggest ??!!
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sikhivahans
over 8 years ago
@enoshe Hi, are you still facing the issue? Shall I take a look at it?
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
ENOSH EZEKIEL
A Score Level 1
over 8 years ago
Yes @sikhivahans...The issue is still existing. The facet is unable to perform for Between, In conditions
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sikhivahans
over 8 years ago
@enoshe Ok, will respond shortly.
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
sikhivahans
over 8 years ago
@enoshe Hi, I am not sure if you have observed the logs while experiencing the error. Below mentioned is what I have observed in the logs and I don't think it's possible to use 'between' operator as per the error message contents and I am slightly surprised about this behavior.
Caused by: com.appiancorp.suiteapi.common.exceptions.AppianRuntimeException: com.appiancorp.suiteapi.common.exceptions.AppianException: No valid filter operator given for filter on [firstName]. Valid operators are: [[=, <>, >, >=, <, <=, starts with, ends with, includes]]. (APNX-1-4203-016)
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
0
ENOSH EZEKIEL
A Score Level 1
over 8 years ago
Thats right @sikhivahans !! Even I'm surprised! :)
Also I'm not sure about how to achieve this scenario mentioned above!
Cancel
Vote Up
0
Vote Down
Sign in to reply
Verify Answer
Cancel
>