Attribute names, as you might have guessed, are the names of your attributes, the individual data fields that make up your user profile database (things like displayName or birthday or lastUpdated). If you want to search for users based on their display name, then you use the attribute named displayName:
If you want to search for users based on the city in which they live, you use this attribute:
No big deal there. However, there are a couple of important points to be aware of here. For starters, search query target values are almost always case insensitive; that means you can use any combination of uppercase and lowercase letters and your search will work just fine. For example, to search for users with the familyName Smith, you can use any of the following search queries:
familyName = "Smith" familyName = "smith" familyName = "SMITH" familyName = "sMItH"
By default, letter casing doesn’t matter when it comes to your target values.
Note. OK, so why did we qualify the previous statement by saying “by default?” That’s because, out of the box, most attributes are case-insensitive, and letter casing doesn’t matter. However, it’s possible to configure attributes to be case-sensitive. To determine which of your attributes are case-sensitive and which ones, aren’t, take a look at the Manage Schemas page.
But case-insensitivity is typically true only with target values. When it comes to attribute names, uppercase and lowercase letters are extremely important. For example, the official attribute name for a user’s display name is written like this: displayName. To search for a user based on his or her display name, you must use the name displayName. This search query works:
displayName = "Bob Jones"
However, this next search query fails with the error message The field with path ‘DisplayName’ does not exist:
DisplayName = "Bob Jones"
Why do we get that error message? Because the attribute name must be entered as displayName; anything else results in failure. As far as the Console is concerned, there is no attribute named DisplayName.
Admittedly, memorizing the casing for each and every letter in each and every attribute name might seem like a daunting task. Fortunately, you can go to the Manage Profiles page and click Searchable fields in order to bring up a dialog box that shows which attributes are searchable as well as the exact spelling and letter casing of each of these attribute names: