Conditionally Show 'Where Clause' search box

Posted by on in Asset and Facilities Management
  • Font size: Larger Smaller
  • Hits: 743
  • 0 Comments
  • Subscribe to this entry
  • Print

On one of the IBM developerWorks forums, a recent question came up on how to conditionally show/hide the ‘Where Clause’ for a specific set of users.

Hi, I want to hide the Clause where  from the List view in all application in Maximo 7.1. In security application, I give access to signature option “serachwhere” with condition to such users. But it seems that the condition is not validated. To be sure that my condition is true, I give access to signature option “serachwhere” if the condition (1=2) is true. But when I log on into an application in maximo, I find that the clause where is always there. There is any help! Thanks.

While the original request made it sound like all users should be excluded from seeing the ‘Where Clause’, a few clarifications and the request was to be able to exclude seeing the ‘Where Clause’ drop down for only some users. I responded back that you could use a Person Group, a Conditional Expression, and apply the Conditional Expression on the application’s sigoption for using the ‘Where Clause’.

Here’s the breakdown of how to set it up in Maximo.

Person Group Setup

Person Groups are a little gem I thought more Maximo admins would use. A Person Group is exactly what it sounds like… a group or person records. The beauty of a person group is that it can be updated independently of any query or conditional expression. So when a user is needed to be added or dropped from a group, you can update the Person Group and not have to touch the original query or conditional expression.

In this case I created a new group and added just my testuser1 user to the group.

Anyone with access to the Person Group app (Administration > Resources > Person Group) can then add, or remove, a person record from the list.

Conditional Expression

Next you setup a Conditional Expression (Administration > Conditional Expression Manager) to create a condition. Conditional Expressions are small (or large) SQL snippets to test the condition of something in Maximo. The example below is a condition that will check to see if the current user is not in the Person Group I created above. The goal is that anyone not in the group will be allowed to see the ‘Where Clause’.

The field :&USERNAME& is a built in shortcut in Maximo to return the userid value of the current user. The condition then checks to see if the current user is not (<>) in list of people in the Person Group ‘1028’.

You can change the expression to be:

:&username& = (select resppartygroup from persongroupteam where :&username& = resppartygroup and persongroup = '1028')

This would then check to make sure a user is in the person group.

Apply Condition to Sigoption

The final step is to apply the Conditional Expression to the signature option that allows access to the ‘Where Clause’. In the example shown below, I added the Condition Expression on a cloned version of the Purchase Requisition (PR) app.

Based on the login in the Conditional Expression, Maximo will allow access to the ‘Where Clause’ sigoption as long as the current user is not in the person group ‘1028’. Use the alternate expression from above to allow access to the ‘Where Clause’ drop down to only users that are in person group ‘1028’.

Result in Application

Now when user testuser1 logs into Maximo and goes to the PR application, the user can see the Advanced Search box, but cannot access the ‘Where Clause’ dropdown.

0
Jason has been in the engineering and reliability field for over 20 years. He currently leads capital expenditure and reliability projects for a large food manufacturer located in southern Minnesota. Jason has been working with the IBM Maximo application for over 10 years, focusing on business process development and reporting
Comments are not available for public users. Please login first to view / add comments.