Friday 7 September 2012

Maximo 7: System properties objects/tables

System properties are storing in below objects:

1. MAXPROP
2. MAXPROPVALUE
3. MAXPROPINSTANCE

1. MAXPROP: This object stores the header information of system property. "propname" is unique.
2. MAXPROPVALUE: This object stores the system property value. "propname" is unique.
3. MAXPROPINSTANCE: This object stores the information of instance properties.

Friday 22 June 2012

BMXAA7136E - Validation failed when the database default values are set to the object during its creation.

Error: BMXAA7136E - Validation failed when the database default values are set to the object during its creation. BMXAA3097E - The person does not exist or is not active.

Solution:

1. Verify if SR.REPORTEDBYID default value is &USERNAME&
2. if it exists, change it to &PERSONID&

Mostly this error will occur, when inserting new record into service requests application. If default value is set to &username&, it is trying to put login username into reportybyid field. Which is wrong. Reportbyid field is validating against Persons, not for user names.

Note: This error will occur, if userid and personid is not same.

Saturday 26 May 2012

Change status of Inbound interface records using MIF


This article may be helpful to Maximo Integration developers.

There may be some cases where some application records maintains in both Maximo and external ERPs. Sometimes, statuses of those records get updated in external ERP and will send data to Maximo. In such cases, Maximo get data from inbound interfaces by using Maximo Integration Framework.

Lets take a example of Invoice application;
  1. Created a Invoice 'I1234'  with line times and status is 'ENTERED'.
  2. Sent Invoice record details to External ERP.
  3. External ERP changed status to 'APPR' and sent Invoice status details to Maximo.
  4. To receive status data from External ERP to Maximo, you must use 'STATUSIFACE' field of INVOICE object.
    1. It means, while creating object structure for inbound interfaces (enterprise services), add STATUSIFACE field of your main object.
    2. Object sturcture: TESTINVOCIE
    3. Object: INVOICE
    4. Exclude/Include fields option: exclude all fields which are not required and make sure STATUSIFACE field is not excluded.
    5. Fields in Invoices are: INVOICENUM,SITEID,STATUS,STATUSIFACE
    6. Inbound data will be : I1234,SITE01,APPR,0
    7. In enterprise services, Object processing rule, set STATUSIFACE = 1.
    8. Inbound data will change to : I1234,SITE01,APPR,1
    9. This will change the status of Invoie to APPR in Maximo.

Thursday 5 April 2012

How to create field validation class which extends MAXTableDomain

1. Write a custom field validation class and extend MAXTableDomain. (import psdi.mbo.MAXTableDomain)
2. Create a constructor and set a relationship with Object (table name).
3. Set a list criteria in the constructor itself (where clause for the above object).
4. If you would like to filter with more where clauses then write a getList() method.
5. Associate this field validation class to attribute in DB Configuration. And make sure that domain is not associated to this attribute.
Sample Class:
public class CustomFeildClass extend MAXTableDomain
{

public CustomFeildClass (MboValue mbv) throws RemoteException
 {
super(mbv);

String thisAttrName = getMboValue().getAttributeName();
setRelationship("FAILURELIST","failurecode=:"+ thisAttrName)
// Note: Here FAILURELIST is a Object. Most of the developers will confuse that it is a relationship name.
 
setListCriteria("parent is null");
//Note: this sets a where condition for the above object.
setErrorMessage("asset","failurecode");
 
 }
public MboSetRemote getList() throws MXException, RemoteException
 {
String additionalWhere ="orgid=:orgid";
setListCriteria(additionalWhere);
//Note: this sets additional where conditional to display when user clicks on lookup.
}
}
 

Wednesday 4 April 2012

How to create custom condition class

There are two types of Conditions in Condition Expression Manager:
1. Expression
2. Class


To use Type Class in Condition, need to create a custom condition class.
1. Create a custom condition class which implements CustomCondition interface.
eg:
public class ConditionClass implements CustomCondition {
public boolean evaluateCondition(MboRemote mbo, Object param)throws MXException, RemoteException
if(<business logic>)

{
<business logic>
return true;
}
else{
<business logic>
return false
}
}
public String toWhereClause(Object parm, MboSetRemote msr)throws MXException, RemoteException

{
<business logic>
 return <sql>
}
}

2. CustomCondition interface have two methods:
a. evaluateCondition(MboRemote mbo, Object param): this method is used to evaluate condition and returns either true or false based on the business logic written in it. This return boolean value.
 b.toWhereClause(Object parm, MboSetRemote msr) : This method is used to return sql to the object which this condition is applied.This returns String.

Friday 10 February 2012

Maximo jre versions


  1. Maximo 7.6 supports jre 1.7
  2. Maximo 7.5 supports jre 1.6
  3. Maximo 7.1.x supports jre 1.5
  4. Maximo 6.x supports jre 1.4
  5. Maximo 5.x supports jre 1.3
 

Setup Maximo in Eclipse

To create a Maximo environment in Eclipse, follow below steps

To create a Maximo Mbo classes in Eclipse:


1. Install Eclipse J2EE version.
2. Create a new Java project. (Eg. name: Maximo Mbo Classes)
3. Go to Java Build Path: click on Add external jars
4. Browse up to <maximoroot>/maximo/applications/maximo/lib and select all (ctrl+a)
5. click add/ok.
6. Click on add class folder and browser <maximoroot>/maximo/applications/maximo/businessobjects/classes and click ok.
7. Create a new package.
8. Create a new class and enter super class as any mbo (psdi.app.po)  (For e.g. public class Test extends PO )

To create a Maximo Bean classes in Eclipse:

1. Create a new Java project. (Eg. name: Maximo Bean Classes)
2. . Click on add class folder and browser <maximoroot>/maximo/applications/maximo/maximouiweb/web-inf/classes and click ok.

Creating a new Maximo Service

Upon Maximo start up all the services will initialize. These services are stored in MAXSERVICE table.

To create a new Service in Maximo 7.1, follow the steps

Step 1: Go to Database configuration --> List Tab
Step 2: Click on "Select Action Menu" and select "Services"
Step 3: A dialog box will open and display all the services.
Step 4: Click on New Row.
Step 5: Enter your service name and class name (service class) path.
Step 6: Enter id as 1000 or above and click ok.
Now new service is created.

Note: To create a Maximo custom service class you need to extend AppService class. If you want to use this service class methods in your mbo classes, you have to define your method as static.

Maximo SOAPUI error javax.xml.ws.WebServiceException

SOAPUI error while sending payload to below url (in cluster environment) http://localhost:9080/meaweb/services/MXASSET Error : <f...