Expand my Community achievements bar.

SOLVED

Read an XML Data type of workbench process through Java

Avatar

Level 4

Hi All,

I have an workbench process which has an output parameter as a XML as data type.

How can I read it through my java code and convert it into string.

Any help please.

Thanks,
Sobhan

1 Accepted Solution

Avatar

Correct answer by
Level 3

There's really nothing complex to do here. In your process, update your string variable with the xml variable and the conversion will happen for you automatically. Don't use java to do this.

View solution in original post

2 Replies

Avatar

Level 6

There are muliple ways to handle xml reponse one of the ways is parsing xml InputStream using DocumentBuilderFactory

here is one good resource:

java - HTTP request for XML file - Stack Overflow

How to read XML response from a URL in java? - Stack Overflow

Avatar

Correct answer by
Level 3

There's really nothing complex to do here. In your process, update your string variable with the xml variable and the conversion will happen for you automatically. Don't use java to do this.