<%
final String DBDRIVER="org.gjt.mm.mysql.Driver";
final String DBURL="jdbc:mysql://localhost/mldn";
final String DBUSER="root";
final String DBPASSWORD="123";
Connection conn=null;
%>
<%
try{
Class.forName(DBDRIVER);
conn=DriverManager.getConnection(DBURL,DBUSER,DBPASSWORD);
Statement stmt=conn.createStatement();
String sql="insert yyp values('shz','xxy',234);";
stmt.executeUpdate(sql);
stmt.close();
}
catch(Exception e)
{
out.print(e);
}
%>
final String DBDRIVER="org.gjt.mm.mysql.Driver";
final String DBURL="jdbc:mysql://localhost/mldn";
final String DBUSER="root";
final String DBPASSWORD="123";
Connection conn=null;
%>
<%
try{
Class.forName(DBDRIVER);
conn=DriverManager.getConnection(DBURL,DBUSER,DBPASSWORD);
Statement stmt=conn.createStatement();
String sql="insert yyp values('shz','xxy',234);";
stmt.executeUpdate(sql);
stmt.close();
}
catch(Exception e)
{
out.print(e);
}
%>