Jump to content
groovyPost Forums

Recommended Posts

def one = text1.EmployeeDataReplicationConfirmation.EmployeeDataReplicationConfirmation.collect { it.personId.text() }
def two = text2.queryCompoundEmployeeResponse.CompoundEmployee.collect { it.person.person_id.text() }
def intersect = one.intersect(two)
println((one - intersect) + (two - intersect))

 

In the text 1 and text2 fields are different ids. This command will give me IDs that are the same in both. But he gives them to me like this:[6107, 10140, 11774] But i need it in XML.. like ..

 

<Person>
<User>
<userid>6107</userid>
</User>
<User>
<userid>10140</userid>
</User>
<User>
<userid>11774</userid>
</User>

how can i do it ? Thanks :)

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Who's Online   0 Members, 0 Anonymous, 10 Guests (See full list)

    There are no registered users currently online

×
×
  • Create New...