Maximo Open Forum

 View Only

 Deactivating Person records when still on Revised/Inactive records

Jump to Best Answer
  • Administration
Jason Verly's profile image
Jason Verly posted 04-20-2022 22:19
I'm curious how others have handled deactivating employees in the Person app when they are still listed on inactive or revised records. Our biggest struggle is finding a way a normal can deactivate a Person record and not have to give them SQL server access or require an administrator to handle an activity that should be managed at the plant. 

Any suggestions on how to deactivate a Person while on a inactive/revised record, like a job plan, would be appreciated. 


EDIT: I have a report that can show me records that are inactive/revised, but the problem is a normal user - e.g. Planner who has full access to Person app - can't inactivate a Person record because of the historical locks on those older records. I'll explore something along the lines of what Danielle suggested. 
Danielle Shaw's profile image
Danielle Shaw Best Answer
I would consider an automation script that either fires on change of person status or is fired by a select action menu item if it's something you don't want to be automatic. You would need to grab an mbo set of all job plans that have the person record as a supervisor.

jpMbo.setValueNull("SUPERVISOR",mbo.NOACCESSCHECK) --> mbo.NOACCESSCHECK should make it so the record can be updated through the automation script even though it is technically locked down.

You could set any fields to null as needed to keep it all in one place.
Rob Jonker's profile image
Rob Jonker
Hi Jason,
We have incorporated this in 'the process' by running a custom report that checks all relevant modules / tables where we want to check if the person is on a record. With this we also capture the fields where Maximo does not give an error on, but you still want to have visibility on.
That report is essential for people in the plant to solve all 'issues' before anyone can be put on 'Inactive'.
Regards,
Travis Herron's profile image
Travis Herron
This won't be the answer you were hoping for. . .

First, I created a script that checks more places than what Maximo checks out-of-the-box. For example, IIRC Maximo will let you deactivate a Person record even if he is the Lead on a PM record.  Assuming that PM is Active, the PM won't generate Work Orders because of the Inactive Lead.  So I check Owner, Supervisor, and Lead fields on Job Plans, PMs, "open" Work Orders, and some other custom areas where the PersonID is a foreign key.  And of course there are other places where this Person may appear, like Person Groups, Asset and Location Custodians or Users, Labor (and therefore possibly future labor assignments, if already scheduled), Crews, and more.

So there's a wide variety of places and processes that would be affected.  Somebody's got to replace that Inactive person. . .but that may, or may not, be a 1-to-1 replacement.  It's possible that the responsibilities of the person who left will be divided among multiple people (especially PMs & the open Work Order backlog, particularly if someone hasn't been hired yet as a replacement).

All that said, it's quite possibly going to take some thought and reshuffling to figure out what to do with all those affected records.  I work for a fairly small, single-site company so I just handle it all myself with a phone call to that person's former supervisor to figure out how everything needs to be redistributed.  For a bigger company, it should probably be a set of nested Job Plans that assigns various people to handle editing the necessary records and culminating with someone actually changing the Person record status.
Tom Peterson's profile image
Tom Peterson
I have been having the same issues for years, so I built a series of SQL queries to find the records that need to be fixed.

I don't know how to build a script like Travis did, and my company isn't so big that the manual fixes are too onerous for me, so I've just been fixing records using MxLoader.

And Jason is correct that out-of-the-box Maximo WILL allow a person to go inactive while still tied to PM/JP records, which will cause you problems later if you don't fix them.
See attached for a text version of my SQL.