Win a copy of The Java Performance Companion this week in the Performance forum!
    Bookmark Topic Watch Topic
  • New Topic

jsp polling

 
kanan devi
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Report post to moderator
i tried following code but it is not working


try
{
Class.forName("com.microsoft.jdbc.sqlserver.SQLServerDriver");
Connection conn = DriverManager.getConnection("jdbc:microsoft:sqlserver://database:1433","sa","123");
Statement st2=conn.createStatement();
String sql1 = "INSERT INTO tab.dbo.poll (a) VALUES ('"+radioVal+"')";
Statement st1=conn.createStatement();
st1.executeUpdate(sql1);
st1.close();
conn.close();
}
catch(Exception ex)
{
out.println(ex.getMessage());
}
%>
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Report post to moderator
Duplicate post.
http://www.coderanch.com/forums/
 
    Bookmark Topic Watch Topic
  • New Topic