Suppressing Default Searches and "Empty" Searches

When you access the Manage Profiles page, the default search query (which returns all user profiles) automatically runs and shows you results of that search:

This also happens any time you access the Manage Profiles page after having logged on. Open the Manage Profiles page and you won’t be greeted by a blank screen. Instead, you’ll see a collection of your user profiles.

Note. By default, that collection consists of your 10 most-recently created user profiles. You can use the arrow buttons at the bottom of the user profile list to page through those search results.

For many organizations, this default behavior is perfectly fine. However, that isn’t true for all organizations. For example, health care organizations bound by the Health Insurance Portability and Accountability Act of 1996 (HIPPA) might not want to do automatic searches that return (and display) all user records. Instead, privacy and confidentiality concerns recommend specifically entering search criteria and then returning only records that meet that criteria. That way, you don’t see any records (i.e., any user profiles) that you didn’t ask to see.

That means that some organizations actually need to see a blank screen each time they access the Manage Profiles page. These organizations would prefer to see something like this when they open the Manage Profiles page:

These same organizations might also want to keep users from doing “empty” searches. By default, Console users can return all their user profiles simply by leaving the Search profiles field blank and then clicking Search; if no search criteria are specified, Console returns all your user profiles. Instead of empty searches, many organizations want you to manually enter something in the Search profiles field before you can search for, and return, user data.

The Janrain Console enables you to suppress both default searches and empty searches. In other words, you can configure the Console so that, when you first access the Manage Profiles page, you won’t see any user profiles; this configuration also ensures that you won’t be able to perform a search without entering a search query. In turn, this enables organizations to leverage the full power of the Janrain platform yet remain fully mindful of user privacy and confidentiality.

Perhaps best of all, configuring the Console to suppress default searches and empty searches is remarkably easy: all you need to do is add the {entity_type}_search_allow_empty client setting to your Janrain configuration. (For more information on adding client settings, see the article API Clients and Permissions). In other words, you just need to complete the following procedure:

  1. From anywhere within the Janrain Console, click Manage Application:
  2. On the Manage Application page, clicking Edit Settings:
  3. On the Edit Settings page, click the Add Setting icon:
  4. Click Select setting key and then select the search_allow_empty setting for the entity type in question. For example, to suppress empty searches on the user entity type, select user_search_allow_empty:
  5. Click Value, and then click false:
  6. Click the Save Settings icon:

After the Console settings have been refreshed (a process that might take 5 minutes or so), you’ll no longer see a set of default search results when you access the Manage Profiles page (at least not for the user entity type; search suppression is done on an entity type-by-entity type basis). Instead, you’ll see something like this:

The message Please submit a search term to view records lets you know that a search query has not been executed. This differentiates a suppressed search query from a query that simply failed to find any records. In the latter case, you’ll see the message No records found instead:

The {entitytype}_search_allow_empty setting also prevents you from doing an empty search. To verify this, go to the Manage Profiles page, leave the Search profiles field blank, and then click Search. Instead of getting back all your user profiles, you’ll see the following message:

The preceding message tells you that you must enter a valid search query in the Search profiles field before you can return user data.

If you have additional entity types and you want to suppress default searches and empty searches for those profiles, simply add a similar setting for each entity type. 

To restore the default behavior (and to again allow both default searches and empty searches), either delete the search_allow_empty setting, or set the value to true.