import java.io.*; import java.sql.*; public class Insert { int vid,vage,vdid; String vnm; Connection conn; Statement st; ResultSet rs; String qry,driver,url; public void read(int id,String name,int age) { vid=id; vnm=name; vage=age; } public void process() { try{ driver="com.mysql.jdbc.Driver"; //mysql database driver url="jdbc:mysql://localhost/mukesh"; Class.forName(driver); conn=DriverManager.getConnection(url,"root","kumar"); qry="insert into emp(eid,ename,eage) values("+vid+",'"+vnm+"',"+vage+")"; System.out.println("qry = "+qry); st=c...
FOR COMP SCIENCE & IT