IBM Support

Including worklog in the Maximo Integration Framework

Question & Answer


Question

How do I include worklog when sending data in using the Maximo Enterprise Adapter (MEA) or Maximo Integration Framework (MIF)?

Answer

For example, assume you want to add worklog to SR.

1. Build a relationship on SR to link WORKLOG to SR.

Create a relationship, MODIFYWORKLOG, in Database Configuration for the SR object, similar to the one used on the TICKET table. The child object is WORKLOG and the Where Clause is

recordkey=:ticketid and class=:class



2. Create an object with two objects, SR and WORKLOG. Use the relationship MODIFYWORKLOG.

Go To Integration -> Object Structures

Create the object structure, MXSR.

- Add MBO SR.

- Add WORKLOG as a child of SR with relationship MODIFYWORKLOG.

object=SR


Select Action -> Exclude/Include Fields
Persistent fields: HASLD - exclude
Non-persistent fields: DESCRIPTION_LONGDESCRIPTION - include

object=WORKLOG
Select Action -> Exclude/Include Fields
Persistent fields: HASLD - exclude; RECORDKEY - exclude
Non-persistent fields: DESCRIPTION_LONGDESCRIPTION - include

3. Sample xml would look similar to the following snippet:


<SR>
<TICKETID>X1016</TICKETID>
<CLASS>SR</CLASS>
<DESCRIPTION>This is the description</DESCRIPTION>
<STATUS maxvalue="NEW">NEW</STATUS>
<STATUSDATE>2004-08-31T13:25:59-04:00</STATUSDATE>
...
<WORKLOG>
<LOGTYPE maxvalue="CLIENTNOTE">CLIENTNOTE</LOGTYPE>
<CREATEBY>MAXADMIN</CREATEBY>
<CREATEDATE>2010-04-06T13:39:28-04:00</CREATEDATE>
<CLIENTVIEWABLE>0</CLIENTVIEWABLE>
<DESCRIPTION>test summary</DESCRIPTION>
<MODIFYBY>MAXADMIN</MODIFYBY>
<MODIFYDATE>2010-04-06T13:39:43-04:00</MODIFYDATE>
<DESCRIPTION_LONGDESCRIPTION>test details</DESCRIPTION_LONGDESCRIPTION>
</WORKLOG>
</SR>

Note: if adding worklogs to an object that already has existing worklog entries, use the action AddChange, otherwise the worklogs will be replaced.

<SR action=AddChange>

<WORKLOG action=AddChange>

[{"Product":{"code":"SSLKT6","label":"Maximo Asset Management"},"Business Unit":{"code":"BU005","label":"IoT"},"Component":"MEA: Generic","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"6.2.1;6.2.2;6.2.3;6.2.4;6.2.5;6.2.6;6.2.7;6.2.8;7.1;7.1.1;7.5;7.6","Edition":""},{"Product":{"code":"SSLKYL","label":"Maximo Enterprise Adapter"},"Business Unit":{"code":"BU005","label":"IoT"},"Component":null,"Platform":[{"code":"","label":""}],"Version":"","Edition":""}]

Document Information

Modified date:
17 June 2018

UID

swg21428253