Migration Solutions for ColdFusion Applications to ASP.NET
      
New Atlanta Product Forums Profile | Search | Login | RSS
New Topic Reply   Previous Page  Page: 1   Next Page

Thread: how to do the PreparedStatement for Arrays or ArrayList?
Created on: 06/20/17 02:49 AM Replies: 0
jamesrivard


Joined: 06/16/17
Posts: 2
how to do the PreparedStatement for Arrays or ArrayList?
06/20/17 2:49 AM

Dear expert,


I have a table name tutor where one of the column named subject has mulitples values.

First, I have a jsp form and user can tick as many checkboxes, and the values will go into the subject column of my table - tutor in the database.

But, I do not know how to set and get the subject in order for the values of the checkboxes to be inserted into database.
1
ps.setString(13, m.getRemark());
2
List<String> list = Arrays.asList(m.getSubject());
3
ps.setArray(14, (Array) list); // ps is the PreparedStatement
please help.
Thanks.

<a href=http://blog.advids.co/20-awesome-landing-page-video-explainer-examples-from-high-conversion-websites/>Landing page video</a>
Link | Top | Bottom

New Post
Please login to post a response.


company media information terms of use privacy policy contact us
This page was dynamically built on the BlueDragon CFML Engine