Saturday, February 2, 2013

OBIEE Auto complete prompts

This time I will talk about Auto Complete Prompts. This feature was introduced in 11.1.1.6.0 and is covered in System Administrators Guide chapter 18.4 (18 is a great chapter to read anyway). Simple search in the net will find few posts available on the issue here, here and here, for example. So why do I bother? First to remind myself of the feature (I always forget it), second to go a little deeper into the syntax.

Bellow is the default text I copied from the text book (chater 18.4).
In the end of this post I have the code I use on my system.  
 So what we should do? 
 Go to instanceconfig.xml that is located in MiddleWareHome/instances/instance2/config/OracleBIPresentationServicesComponent/coreapplication_obips1. There you need to check for <Prompts> section (it probably doesn't exist). Directly under the general <ServerInstance> section (not within any other) there should be:
<Prompts>
<MaxDropDownValues>256</MaxDropDownValues>
<AutoApplyDashboardPromptValues>true</AutoApplyDashboardPromptValues>
<AutoSearchPromptDialogBox>true</AutoSearchPromptDialogBox>
<AutoCompletePromptDropDowns>
<SupportAutoComplete>true</SupportAutoComplete>
<CaseInsensitive>true</CaseInsensitive>
<MatchingLevel>MatchAll</MatchingLevel>
<ResultsLimit>50</ResultsLimit>
</AutoCompletePromptDropDowns>
</Prompts>


Next restart, at least, the presentation services of the BI Server (the guide advises to "Restart Oracle Business Intelligence").
Now you enter the dashboard and check the prompt with anticipation and ... probably nothing! Why?
They are one or two more things  to update.
Probably in your user My Account definitions
The Prompts Auto-Complete is set to Off.

Turn it On.
Now it should work, unless in the Dashboard Properties you deliberately turned it off:

So you have the Prompts Auto-Complete feature working now. Lets go back and have a closer look at the instanceconfig.xml modifications we made.

They are 4 parts in the Prompts section:

<MaxDropDownValues>256</MaxDropDownValues>
This part of the Prompts definition is general and has nothing to do with Auto-Complete. It's in the documentation, because the description is general "Configuring Prompts" and not "Configuring Auto-Complete Prompts". It's especially redundant since 256 is the default value :(
   MaxDropDownValues Specifies the maximum number of choices to display in the following locations:
  • In choice lists in dashboard prompts.
  • In the Available list of the Select Values dialog That is displayed when the user clicks the Search link in a prompt and the More link to display additional choices.
  • In the Available list of the Select Values dialog when the user performs a search in that dialog.


<AutoApplyDashboardPromptValues>true</AutoApplyDashboardPromptValues>
Again, nothing to do with Auto-Complete and since the default is True... No need to have this line in unstanceconfig file.
In simple terms, this options allows you to use the 11.1.1.6 option of hiding the apply button if you want.
    AutoApplyDashboardPromptValues Specifies whether to display various fields, as described in the following list:

If True, then
  • The Show Apply Button and Show Reset Button fields are displayed on the Edit Page Settings dialog.
  • The Prompts Apply Buttons and Prompts Reset Buttons fields are displayed in the
  • Dashboard Properties dialog.
  • The Prompt Buttons on Current Page option is displayed on the Dashboard builder’s Tools menu.
If False, then
  • The Show Apply button and Show Reset button fields are not displayed on the  Edit Page Settings dialog.
  • The Prompts Apply Buttons and Prompts Reset Buttons fields are not displayed in the Dashboard Properties dialog.
  • The Prompt Buttons on Current Page option is not displayed on the Dashboard builder’s Tools option.

<AutoSearchPromptDialogBox>true</AutoSearchPromptDialogBox>
This option is relevant to Auto-Complete as well, but since the default is True anyway, no need to have it in instanceconfig file.
AutoSearchPromptDialogBox Specifies whether search results are displayed and
highlighted when the user types the search parameter (without clicking the Search button).


 The last part is:
<AutoCompletePromptDropDowns>
         <SupportAutoComplete>true</SupportAutoComplete>
         <CaseInsensitive>true</CaseInsensitive>
         <MatchingLevel>MatchAll</MatchingLevel>
         <ResultsLimit>50</ResultsLimit>
</AutoCompletePromptDropDowns>

Now we are in business.  AutoCompletePromptDropDowns is the section dealing with Auto-Complete prompts.
Lets check all 4 components.

SupportAutoComplete enables or disables the auto-complete functionality of prompts. A setting of True turns auto-complete on, which means that the Prompts Auto-Complete field is displayed and is set to On in the My Account dialog and in the Dashboard
Properties dialog.
A setting of False turns auto-complete off, which means that the auto-complete fields in the My Account and Dashboard Properties dialogs are not available.
Since the default for non Exalytics machines is False. You must have this line.

CaseInsensitive specifies whether the auto-complete functionality is case-insensitive. If set to True, case is not considered when a user enters a prompt value such as "Oracle" or "oracle." If set to False, case is considered when a user enters a prompt value, so the user must enter "Oracle" and not "oracle" to find the Oracle record. The system recommends the value with the proper case.
The default is True, since it what you want in most cases, you can omit this line.

MatchingLevel specifies whether the auto-complete functionality uses matching to find the prompt value that the user enters into the prompt field. These settings do not apply when the user accesses the Search dialog to locate and specify a prompt value. Use the following settings:
  • StartsWith - Searches for a match that begins with the text that the user types. For example, the user types "M" and the following stored values are displayed: "MicroPod" and "MP3 Speakers System".
  • WordStartsWith - Searches for a match at the beginning of a word or group of words. For example, the user types "C" and the following values are displayed: "ComCell", "MPEG Camcorder", and "7 Megapixel Digital Camera".
  • MatchAll  - Searches for any match within the word or words.
Since the default is MatchAll, you can omit this line in most cases.

ResultsLimit specifies the number of matching values that are returned when the auto-complete functionality is enabled.
The default is 50. You should have this line only if you want a different value.

So on my computer I have only the following change in instanceconfig.xml file that is located in MiddleWareHome/instances/instance2/config/OracleBIPresentationServicesComponent/coreapplication_obips1.

<Prompts>
<AutoCompletePromptDropDowns>
<SupportAutoComplete>true</SupportAutoComplete>
<ResultsLimit>30</ResultsLimit>
</AutoCompletePromptDropDowns>
</Prompts>



There is no problem with the full list of parameters that appear at the beginning of this post. They are just unnecessary and create additional clutter in instanceconfig file.

Anyway, the result looks like this:
Bear in mind, there is a reason auto-complete is default in Exalytics only. If the search takes too much time to run. It annoys the user.

5 comments:

  1. Pretty article! I found some useful information in your blog,

    http://www.tekclasses.com/

    ReplyDelete

  2. This blog is an attempt to explore option of full-text catalog search.



    http://www.tekclasses.com/

    ReplyDelete
  3. hi i have implemented but when name is long it is not shown result
    e.g

    choice list contain "BAJAJ" but it is not shown in prompt dialog.
    its only work on 2 character. and if i refresh page and type "BAJAJ" very quickly then it's display. i think there is some problem with auto complete or i'm doing anything wrong.

    ReplyDelete
    Replies

    1. Manish, just keep on typing in any speed you like.

      Delete
    2. Hi thanks for reply,
      i have tried but not luck,problem is very strange behavior when first time i am typing text in speed like 'MARUTI' dialog shown msg please wait then it is shown in dialog now i have deleted some charater using backspape 'MAR' but dialog not showing any result.

      Delete