Oracle Analytics Cloud and Server

Welcome to the Oracle Analytics Community: Please complete your User Profile and upload your Profile Picture

LOWER

Received Response
212
Views
28
Comments
User_I0GH4
User_I0GH4 Rank 3 - Community Apprentice
Hello,

I created a prompt for the user to enter a word.
I would like the user to have the option of typing the word in uppercase or lowercase.

I created the formula LOWER("Bidder".."Supplier name")

On the other hand, it is absolutely necessary that the user enters the word in lower case so that
the results are displayed. If the user enters the word in uppercase, it does not display.

It is not practical.

Do you know another formula that would allow the user to display the word
lowercase and uppercase?

Thank you!


«13

Answers

  • Jerry Casey
    Jerry Casey Rank 6 - Analytics Lead

    Use the prompt to initialize a presentation variable, say, varSupplier. They can enter a value in upper or lower case.

    In your query, use a filter like this:

    UPPER('@{varSupplier}{xxx}')=UPPER("Bidder"."Supplier Name")

    This way, their prompt entry and the filtered column are both tested in upper case. I've used this many times.

  • User_I0GH4
    User_I0GH4 Rank 3 - Community Apprentice
    Yes thank you very much
    
    This is what I want users to be able to enter a word in uppercase or lowercase
    
    I have never used a presentation variable. I am a beginner.
    Can you tell me how to create a presentation variable?
    
    Thank you!
    


  • Jerry Casey
    Jerry Casey Rank 6 - Analytics Lead

    Is your prompt in the query itself or is it in a dashboard prompt? Let's assume a dashboard prompt.

    Choose "Variable Prompt":

    Name your variable, user input and data type. (also add a default value, if you want:

    Generally, Presentation Variables are referenced like this: @{varSupplier}{'default value'}, or '@{varSupplier}{default value}' although you should do some reading to see other variations. This is a good link, although someone might have a more recent one:

    http://obieetutorialguide.blogspot.com/2012/02/using-variables-in-obiee.html

    In your case, a query filter of UPPER('@{varSupplier}')=UPPER(your column name) will do what you want.

  • Jerry Casey
    Jerry Casey Rank 6 - Analytics Lead

    I just wrote a long response which disappeared when I hit the "post comment" button. aargh.

    You should read up on PVs, they add tremendous flexibility in your dashboard prompts. In your case, create a variable prompt (you'll see that option when you select the green plus sign).

    Name your variable and select user input and data type:

    In general, for your specific purpose, your query filter should look like I described in my first response.

  • User_I0GH4
    User_I0GH4 Rank 3 - Community Apprentice
    Thanks very much
    
    I created the presentation variable varSupplier.
    
    
    
    Where should I put
    
    UPPER('@{varSupplier}{xxx}')=UPPER("Bidder".."Supplier Name")
    


  • Jerry Casey
    Jerry Casey Rank 6 - Analytics Lead

    In the filter of the query that you are prompting.

  • User_I0GH4
    User_I0GH4 Rank 3 - Community Apprentice
    I wrote in the filter but when I write a word, nothing happens. Why ?
    
    Do you have an example file?
    


  • Jerry Casey
    Jerry Casey Rank 6 - Analytics Lead

    You are showing it in a column editor window. It goes into a filter in the criteria tab. Here's a two-column query, to be filtered on Employee Last Name:

    Select "Filter", then "Convert to SQL":"

    Enter the filter in the "Advanced SQL Editor" window:

    My prompt looks like this:

    My results look like this:

    A slightly more complicated filter adds more function. If you use the LIKE operator and the "%" wildcard character, the user can enter partial spellings and still get results.

     UPPER("Dim All Employees"."Employee Last Name") LIKE UPPER('%@{varNameSearch}{cas}%')

    Results in:


  • User_I0GH4
    User_I0GH4 Rank 3 - Community Apprentice
    I followed your steps. Thank you so much.
    
    I get the following error.
    
    What do you think is the problem?
    


  • You didn't really follow the steps posted, or maybe you followed them too much without looking much at what you were writing and where.

    "Avis"."Titre avis" IN (UPPER('@{varNameSearch}{smith}') = UPPER("Dim All Avis"."Titre avis"))
    

    This isn't a condition in any known query language (SQL or LSQL).

    A condition is an expression that return TRUE or FALSE, therefore it is either a IN or a =, but you can't write a IN ( = ).

    You should take a step back and undo your filters to replace them with what Jerry explained in details (including screenshots).

    With all the due respect (rien de personnel, vraiment), you should also consider having a training on OBIEE or at least SQL, because filters and conditions are a very basic topic that is required to be able to properly build an analysis (or a SQL query, that is what OBIEE generate in the end).