Instance of object Employee different to another instance of object Employee?
1
I have one object 'Employee'. I have two instances of that object (A and B). I would like to know if there is a difference between instance A and instance B. I only would like to know if there is a difference, so true or false will suffice. Is there already some sort of action (already looked in communitycommons), if not how can I create one of my own?
asked
Roeland Strootman
2 answers
2
In Java you can write a generic comparison of two instances by looping over the attributes and/or references and checking for equality. The source code is left as an exercise to the reader :-)
answered
Arjan van IJzendoorn
1
You can create a microflow and do a retrieve action on the object with XPath constraint set on all entities. For instance:
[Name=$Name]
[Birthday=$Birthday]
etc.
Only an exact copy will retrieve the other object otherwise it will always turn empty. You can validate on that.