Check if a particular JSON Object is available or not
Anyway, I got the solution with some Googling:I re-framed it as,
if (!jArray.getJSONObject(j).has("child2")) { map.put("Second Value", "N.A"); } else { map.put("Second Value", jArray.getJSONObject(j).getString("child2")); }
Creating the JSONObject getchild2 = jArray.getJSONObject(j).getJSONObject("child2"); was rather, unnecessary.
And this works, rather perfectly! Refer this for more details: Checking if exists subObject in JSON
Thanks everyone for the help!