符合中小企业对网站设计、功能常规化式的企业展示型网站建设
本套餐主要针对企业品牌型网站、中高端设计、前端互动体验...
商城网站建设因基本功能的需求不同费用上面也有很大的差别...
手机微信网站开发、微信官网、微信商城网站...
import java.util.ArrayList;
import java.util.List;
import org.apache.ibatis.session.SqlSession;
import cn.itcast.javaee.mybatis.util.MybatisUtil;
/**
* 持久层
* @author AdminTC
*/
public class StudentDao {
/**
* 插入学生
*/
public void dynaInsert(Student student) throws Exception{
SqlSession sqlSession = null;
try{
sqlSession = MybatisUtil.getSqlSession();
sqlSession.insert("studentNamespace.dynaInsert",student);
sqlSession.commit();
}catch(Exception e){
e.printStackTrace();
sqlSession.rollback();
throw e;
}finally{
MybatisUtil.closeSqlSession();
}
}
public static void main(String[] args) throws Exception{
StudentDao dao = new StudentDao();
//dao.dynaInsert(new Student(1,"哈哈",7000D));//insert into 表名(*,*,*) values(?,?,?)
//dao.dynaInsert(new Student(2,"哈哈",null));//insert into 表名(*,*) values(?,?)
//dao.dynaInsert(new Student(3,null,7000D));//insert into 表名(*,*) values(?,?)
dao.dynaInsert(new Student(4,null,null));//insert into 表名(*) values(?)
}
}
students_id,
students_name,
students_sal,
#{id},
#{name},
#{sal},
insert into students( ) values( )