This may be going beyond what the OP was asking for, so this could be trimmed/modified, but it's not uncommon that I might want to see all the PM's for a particular building. That could be that the PM:
--is made for a Location, and the Location is in (is a child Location of) the building
--is made for an Asset, and the Asset's Location is in the building
--has a Route, and the Route has a Route Stop that is a Location in the building
--has a Route, and the Route has a Route Stop that is an Asset, and that Asset's Location is in the building.
WHERE siteid = 'MYSITE' and
((location is not null and location in (select location from locancestor where siteid = 'MYSITE' and ancestor = 'BUILDING')) or
(assetnum is not null and assetnum in (select assetnum from asset where siteid = 'MYSITE' and location in (select location from locancestor where siteid = 'PCC' and ancestor = 'BUILDING'))) or
(route is not null and (route in (select route from route_stop where location is not null and location in (select location from locancestor where siteid = 'MYSITE' and ancestor = 'BUILDING')) or
route in (select route from route_stop where assetnum is not null and assetnum in (select assetnum from asset where siteid = 'MYSITE' and location in (select location from locancestor where siteid = 'MYSITE' and ancestor = 'BUILDING'))))))
Then the next trick would be to figure out how to convert that into a Relationship that could be used in the UI, instead of having to manipulate it in the WHERE clause (that not everyone would have access to).
------------------------------
Travis Herron
Pensacola Christian College
------------------------------
Original Message:
Sent: 12-15-2022 16:55
From: Travis Herron
Subject: Search for PMs assigned to assets
Yes, you are right. So it's going to have to be a custom relationship then. Do you need the search to also include Route Stops?
------------------------------
Travis Herron
Pensacola Christian College
Original Message:
Sent: 12-15-2022 16:42
From: Mack Parrott
Subject: Search for PMs assigned to assets
Sounds logical, Travis, but Maximo doesn't behave that way - when I use the drilldown in Search Location Hierarchy, find a location and search, I only get PMs for locations at that level and below.
I'm going to review the other suggestions now.
------------------------------
Mack Parrott
Projetech Inc.
Original Message:
Sent: 12-15-2022 08:57
From: Travis Herron
Subject: Search for PMs assigned to assets
In the Advanced Search dialog, I have the "Search Location Hierarchy" option. I *think* it's an out-of-the-box field (unless I was really OCD and manually renumbered the Control ID in the XML file). Anyways, it uses the PRIMARYSYSLOCPM.ANCESTOR relationship.
So do as Steven said if you know the precise location, else Search Location Hierarchy for, say, finding all the Assets in a building, regardless of where in the building it is.
------------------------------
Travis Herron
Pensacola Christian College
Original Message:
Sent: 12-14-2022 16:31
From: Mack Parrott
Subject: Search for PMs assigned to assets
I've seen this before but can't put my finger on it now - in the PM app, how do you find PMs for assets when you only know the locations they belong to?
#Assets
#WorkManagement
------------------------------
Mack Parrott
Projetech Inc.
------------------------------