IBM Maximo: Cleanup of Start Center: Difference between revisions

From Wiki
(Criou a página com "'''Cleanstartcenters.bat/sh''' is a tool that deletes Start Center configuration data by specific user or for all users. This script is installed on Maximo Administrative...")
 
No edit summary
Line 6: Line 6:
* C:\IBM\SMP\maximo\tools\maximo
* C:\IBM\SMP\maximo\tools\maximo


  <?xml version="1.0" ?>
 
To run this tool, you must run the following command:
 
  C:\IBM\SMP\maximo\tools\maximo>cleanstartcenters.bat -isccleanup.xml
 
where sccleanup.xml is a xml file with a list of users.
 
The '''sccleanup.xml''' has the following syntax
 
<nowiki><?xml version="1.0" ?>
  <document docid="SCCleanup">
  <document docid="SCCleanup">
  <!-- Samples
  <!-- Samples
Line 19: Line 28:
   
   
  '''<!-- PUT TAGS HERE -->'''
  '''<!-- PUT TAGS HERE -->'''
  </startcenters>
  </startcenters>
  </document>
  </document>
</nowiki>


I use this sql command to  
I use this sql command to get the list of status


  select status from maxuser group status
  select status from maxuser group status
after i use this sql command to generate tags to DELETED and INACTIVE users and add to '''sccleanup.xml''' file
   
   
  select '<startcenterbyuser userid="' || userid || '"/>' from scconfig s where userid in (select USERID from maxuser where status = 'DELETED') group by userid
  select '<startcenterbyuser userid="' || userid || '"/>'  
 
from scconfig s  
to generate tags and add to '''sccleanup.xml''' file
where userid in (select USERID from maxuser where status in('DELETED','INACTIVE') ) group by userid
 
After run this command
 
C:\IBM\SMP\maximo\tools\maximo>cleanstartcenters.bat -isccleanup.xml





Revision as of 17:18, 24 July 2023

Cleanstartcenters.bat/sh is a tool that deletes Start Center configuration data by specific user or for all users.


This script is installed on Maximo Administrative Workstation on directory. Example:

  • C:\IBM\SMP\maximo\tools\maximo


To run this tool, you must run the following command:

C:\IBM\SMP\maximo\tools\maximo>cleanstartcenters.bat -isccleanup.xml

where sccleanup.xml is a xml file with a list of users.

The sccleanup.xml has the following syntax

<?xml version="1.0" ?>
 <document docid="SCCleanup">
 <!-- Samples
 
 <startcenters>
 <startcenter id="93"/>
 <startcenterbygroup groupname="SRMSELFSERVICE"/>
 <startcenterbygroup groupname="ITADMIN"/>
 <startcenterbyuser userid="ESPH"/>
 -->
 <startcenters>
 
 '''<!-- PUT TAGS HERE -->'''

 </startcenters>
 </document>

I use this sql command to get the list of status

select status from maxuser group status

after i use this sql command to generate tags to DELETED and INACTIVE users and add to sccleanup.xml file

select '<startcenterbyuser userid="' || userid || '"/>' 
from scconfig s 
where userid in (select USERID from maxuser where status in('DELETED','INACTIVE') ) group by userid


Ver também