title: How to store/retrieve List<string> values from/to database using java
body: <p>so I'd like to know how can i <strong>store</strong> List in one field in database and the type of that field is <strong>VARCHAR2</strong>
  and after that i want to <strong>retrieve</strong> them later to get it in response.</p>
  
  <p>basically my project go like that SoapUI Request ==> Eclipse ==> SQLDeveloper ==> Eclipse ==> SoapUI Response </p>
  
  <p>i have a class that has the definition of the list like that</p>
  
  <pre><code>private String name;
  private int number;
  private List&lt;String&gt;channel;
  public String getName() {
      return name;
  }
  public void setName(String name) {
     this.name= name;
  }
  public String getNumber() {
      return number;
  }
  public void setNumber(int number) {
     this.number= number;
  }
  public String getChannel() {
      return channel;
  }
  public void setChannel(List&lt;String&gt;channel) {
     this.channel= channel; 
  }
  </code></pre>
  
  <p>and it is getting the list that i inserted in the request 
  Ex: [a,b,c,d]
  now i have a problem in storing them in database using stored procedure </p>
  
  <pre><code>database.AddInParameter("NAME",request.getName());
  database.AddInParameter("NUMBER",request.getNumber());
  database.AddInParameter("CHANNEL",request.setChannel());//it crashes here and it is returning NULL
  database.ExecuteNonQuery();
  </code></pre>
  
  <p>and i am getting the data from database like </p>
  
  <pre><code>while (rs.next())
  {
  save.setName(rs.getName());
  save.setNumber(rs.getNumber());
  save.setChannel(rs.getChannel());
  }
  </code></pre>
  
  <p>I am missing something ?
  can someone tell me how to fix it and how can i retrieve the list as a list?</p>