Did you know that you can create lookups in Maximo (in the lookups.xml) with whereclause and attach it to an attribute in application designer. The attribute doesn’t require a domain to be attached to it to show the data in the lookup .
The lookup will simply query the object mentioned in the mboname with the whereclause and display the result. The only drawback to this approach is that there is no validation on the attribute – any value entered in the field would be accepted without any validation.
The where clause also accepts run-time variables such as :user.
This is useful in places such as report request pages where a parameter needs to be passed to the report with a lookup which shows much filtered data then is usually shown in the lookup in the application.
For instance this asset availability report request page has a parameter as Tool which only shows items of type tool and not all the items.
Hello, i’m looking for a solution similar to this. But i need it to flexibel. e.g. If i select linetype “doc” in purchase order, i would like to have the ‘item’ lookup to display only items with commoditygroup “doc”. If i use every other linetype, i would like to have the “item” lookup not to show items with commoditygroup “doc”. Would that be possible in the lookups.xml ? Or else any other solution you can think of would be helpful and much appreciated. Best Regards Hessel
Hello Hessel,
This can be done through lookup.xml but it would be a tricky one. I wouldn’t recommend it. Instead you can write a field class extending MAXTableDomain and pass different where clause based on your conditions in the setListCriteria method.
PK,
Thanks for your response. I’ve not experience with writing a field class. Is that Java customization?
Best regards,
Hessel
Yes that’s java customization.
Hi PK,
Can you help me with a useful reference for the URL or the article on how to use MAXTableDomain and setListCriteria methods?
thanks
Okay, it’s our corporate policy to avoid java customization’s…….
A table domain can do what you require.
Thanks much for this. Great tip, works like a charm.
Hi All,
I need a help in lookup.xml for below requirement.
I am trying to hide few Lookup values(New,INPROG) in Service request list tab. I have created a custom lookup with whereclause and imported it in app designer , mapping also done for new lookup but still the status is showing. Could you please suggests any solution if you have.
Version details : IBM Control Desk 7.5.0.3.
Thanks in advance
Sorry for the late reply.
I don’t think this could be done through configuration. This would require extending the status handler.
Hello, I am new to Maximo. I cannot find out how to download lookups.xml file. I was able to go to App designer and go to WO applicaiton. I was able to download the XML for worder.xml. I cannot figure out how to download lookups.xml. Any help is greatly appreciated.
Hello, I am new to Maximo. I cannot find out how to download lookups.xml file. I was able to go to App designer and go to WO application. I was able to download the XML for worder.xml. I cannot figure out how to download lookups.xml. Any help is greatly appreciated.
Hello, In Application Designer, from the Select Action menu, select Export System XML option, select the blue icon next to LOOKUPS.XML. If you have Maximo 7.6, Export System XML option would be in left side menu.