Solved Bug: 

1)After xml is converted, Json object now is now cast into JSONArray as
an object than a jsonstring.

2)Front end: datatype 'json' is sepcified, else error is thrown