org.json.JSONException: JSONObject["alias"] not a string
<p>I'm trying to get the alias string from the json file.But I'm getting the exception saying alias is not a string. <code>org.json.JSONException: JSONObject["alias"] not a string.</code> </p>

<pre><code>String qsCurrentLine;
    try {
        brq = new BufferedReader(new FileReader("/home/storm/Videos/2.json"));
        try {
            while ((qsCurrentLine = brq.readLine()) != null) {
                //System.out.println(qsCurrentLine);
                //reads the line makes it json object
                JSONObject question=new JSONObject(qsCurrentLine);
                //System.out.println(question);
                JSONArray usersarray=question.getJSONArray("users");
                //System.out.println(usersarray);
                for(int i=0;i&lt;usersarray.length();i++){
                JSONObject questions=usersarray.getJSONObject(i);
                //System.out.println(questions);
                int qus=questions.getInt("id");
                //System.out.println(qus);
                //String alias=questions.getString("alias");
            //String check=questions.getString("answer");
            //System.out.println(check);
            String check1=questions.getString("question");
            //System.out.println(check1);
            String check2=questions.getString("_subtype");
            //System.out.println(check2);
            String check3=questions.getString("_type");
            //System.out.println(check3);
            String check4=questions.getString("options");
            //System.out.println(check4);

                System.out.println("HELLO    "+questions.getString("alias"));

        //  System.out.println(check5);

            int check6=questions.getInt("id");
            System.out.println(check6);

                //System.out.println("This alias " +aliass);

                }
                //JSONObject data25=array.getJSONObject(25);
                //System.out.println(data25);
                //question1060=data25.getString("question_36__option_10160_");
                //System.out.println("the question number of 1060: "+question1060);
            }
        } catch (JSONException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        } catch (IOException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }

    } catch (FileNotFoundException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    }
</code></pre>

<p>I'm getting all other String values but when I try to get the alias String I'm getting the exception I don't understand why?</p>

<p>Here this the sample of my json file.</p>

<pre><code>{"answer":null,"question":"&lt;h1 style=font-family:Lato, sans-serif;font-weight:600;font-size:28px;&gt;   Your response to our survey will help us identify how we are serving the needs of different companies.&lt;\/span&gt;&lt;\/span&gt;","_subtype":"instructions","_type":"SurveyDecorative","options":"[]","alias":null,"id":73}
</code></pre>

<p>even if alias is NULL it should get the null string can any of you explain this why it is happening like this.</p>

<p>Thanks in Advance</p>