title: Reading a value from String to String Array in Java
body: <p>How to read a String into a String array in java , I have the following code :</p>
  <pre><code>for (int i=0 ; i&lt;=jArr2.length() ; i++ ) {
      JSONObject jArrOb = jArr2.getJSONObject(i);
      String empIDStr = jArrOb.getString(&quot;emp_id&quot;);
      String[] plant_ID[i] = empIDStr;             
  }
  </code></pre>
  <p>The compiler shows an error stating that String cannot be read into String Array. I am basically moving the values of JSON object into a String Array.</p>