diff --git a/mogdb-springmvc-mybatis-demo/pom.xml b/mogdb-springmvc-mybatis-demo/pom.xml
new file mode 100644
index 0000000000000000000000000000000000000000..a0d60c188ce033d88e28d6277bc383c3755b642b
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/pom.xml
@@ -0,0 +1,398 @@
+
+
+
+
+ io.mogdb
+ mogdb-demo
+ 1.0
+
+ 4.0.0
+
+ com.enmotech
+ mogdb-springmvc-mybatis-demo
+ war
+ mogdb-springmvc-mybatis Maven Webapp
+
+
+ UTF-8
+ 1.8
+ 1.8
+ 5.2.4.RELEASE
+ 4.0.0-b07
+ 1.2
+ 1.1.18
+ 3.2.7
+ 1.2.2
+ 5.0.1
+ 6.0.0
+ 4.13
+ 1.7.25
+ 2.8.2
+
+
+
+
+
+ org.springframework
+ spring-web
+ ${spring.version}
+
+
+
+ org.springframework
+ spring-core
+ ${spring.version}
+
+
+
+ commons-logging
+ commons-logging
+
+
+
+
+
+ org.springframework
+ spring-beans
+ ${spring.version}
+
+
+
+ org.springframework
+ spring-context
+ ${spring.version}
+
+
+ commons-logging
+ commons-logging
+
+
+
+
+
+ org.springframework
+ spring-context-support
+ ${spring.version}
+
+
+
+ org.springframework
+ spring-aop
+ ${spring.version}
+
+
+
+ org.springframework
+ spring-aspects
+ ${spring.version}
+
+
+
+ org.springframework
+ spring-expression
+ ${spring.version}
+
+
+
+ org.springframework
+ spring-tx
+ ${spring.version}
+
+
+
+ org.aspectj
+ aspectjweaver
+ 1.9.2
+
+
+
+ org.springframework
+ spring-test
+ ${spring.version}
+
+
+
+
+ org.springframework
+ spring-webmvc
+ ${spring.version}
+
+
+
+
+ javax.servlet
+ javax.servlet-api
+ ${javax.servlet.version}
+
+
+
+ jstl
+ jstl
+ ${jstl.version}
+
+
+
+
+ org.mybatis
+ mybatis
+ ${mybatis.version}
+
+
+
+
+ org.opengauss
+ opengauss-jdbc
+ ${opengauss.jdbc.version}
+
+
+
+
+
+
+
+
+
+ com.github.pagehelper
+ pagehelper
+ ${pagehelper.version}
+
+
+
+
+ org.springframework
+ spring-jdbc
+ ${spring.version}
+
+
+
+
+ com.mchange
+ c3p0
+ 0.9.5.2
+
+
+
+ org.mybatis
+ mybatis-spring
+ ${mybatis.spring.version}
+
+
+
+
+ com.alibaba
+ fastjson
+ 1.2.69
+
+
+
+ org.apache.commons
+ commons-collections4
+ 4.4
+
+
+
+ org.apache.commons
+ commons-lang3
+ 3.8.1
+
+
+
+ junit
+ junit
+ ${junit.version}
+
+
+
+
+ org.oracle.com
+ ojdbc
+ 7.1
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ com.fasterxml.jackson.core
+ jackson-core
+ 2.9.3
+
+
+
+ com.fasterxml.jackson.core
+ jackson-databind
+ 2.9.3
+
+
+
+
+ org.slf4j
+ slf4j-api
+ ${slf4j-log4j.version}
+
+
+ org.slf4j
+ jcl-over-slf4j
+ ${slf4j-log4j.version}
+ runtime
+
+
+
+
+
+ org.apache.logging.log4j
+ log4j-core
+ ${log4j2.version}
+ runtime
+
+
+ org.apache.logging.log4j
+ log4j-web
+ ${log4j2.version}
+ runtime
+
+
+ org.apache.logging.log4j
+ log4j-api
+ ${log4j2.version}
+ runtime
+
+
+ org.apache.logging.log4j
+ log4j-slf4j-impl
+ ${log4j2.version}
+ runtime
+
+
+
+
+
+ mogdb-spring-mybatis
+
+
+
+ maven-clean-plugin
+ 3.1.0
+
+
+
+ maven-resources-plugin
+ 3.0.2
+
+
+ maven-compiler-plugin
+ 3.8.0
+
+
+ maven-surefire-plugin
+ 2.22.1
+
+
+ maven-war-plugin
+ 3.2.2
+
+
+ maven-install-plugin
+ 2.5.2
+
+
+ maven-deploy-plugin
+ 2.8.2
+
+
+
+ org.apache.tomcat.maven
+ tomcat8-maven-plugin
+ 3.0-r1655215
+
+ src/main/webapp
+ 8099
+ UTF-8
+
+
+
+
+
+
+
+
+ nexus
+ Team Nexus Repository
+ http://192.168.64.138:8081/nexus/content/groups/public
+
+ true
+
+
+ true
+
+
+
+
+
+
+ nexus
+ Team Nexus Plugin Repository
+ http://192.168.64.138:8081/nexus/content/groups/public
+
+ true
+
+
+ false
+
+
+
+
+ alfresco-public
+ https://artifacts.alfresco.com/nexus/content/groups/public
+
+
+ alfresco-public-snapshots
+ https://artifacts.alfresco.com/nexus/content/groups/public-snapshots
+
+ true
+ daily
+
+
+
+
+
+
+ releases
+ http://192.168.64.138:8081/nexus/content/repositories/releases
+
+
+ snapshots
+ http://192.168.64.138:8081/nexus/content/repositories/snapshots
+
+
+
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/controller/IndexController.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/controller/IndexController.java
new file mode 100644
index 0000000000000000000000000000000000000000..bd44e93b366d14ea34bbfb6cdf5f6a00de5f967d
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/controller/IndexController.java
@@ -0,0 +1,74 @@
+package io.mogdb.springmvc.mybatis.controller;
+
+import io.mogdb.springmvc.mybatis.entity.StudentEntity;
+import io.mogdb.springmvc.mybatis.service.MyStudentService;
+import io.mogdb.springmvc.mybatis.service.OmOfferingInstService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Controller;
+import org.springframework.ui.ModelMap;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RequestMethod;
+import org.springframework.web.bind.annotation.ResponseBody;
+
+import java.sql.SQLException;
+import java.util.Map;
+
+@RequestMapping("/")
+@Controller
+public class IndexController {
+ @Autowired
+ private MyStudentService myStudentService;
+
+ @Autowired
+ private OmOfferingInstService omOfferingInstService;
+
+ @RequestMapping(value = "/", method = RequestMethod.GET)
+ public String index() {
+ return "index";
+ }
+
+ @RequestMapping("/index/v1")
+ @ResponseBody
+ public String indexString() {
+ return "index";
+ }
+
+ @RequestMapping(value = "/index/test", method = RequestMethod.GET)
+ public String printHelloWorld(ModelMap modelMap) {
+ // add attribute to load modelMap
+ modelMap.addAttribute("message",
+ "test mogdb spring mybatis in Spring MVC!");
+ // return the name of the file to be loaded "test.jsp"
+ return "test";
+ }
+
+ @RequestMapping("/index/testTs")
+ @ResponseBody
+ public String testTrans(StudentEntity studentEntity) {
+ return myStudentService.testTs(studentEntity);
+ }
+
+ @RequestMapping("/index/testTsV2")
+ @ResponseBody
+ public String testTsV2(StudentEntity studentEntity) {
+ return myStudentService.updateV2(studentEntity);
+ }
+
+ @RequestMapping("/index/testBatch")
+ @ResponseBody
+ public String testBatch(Map data) {
+ // 分区表,inset into select
+ // omOfferingInstService.batchInsertInst(data);
+ // 非分区表,insert into select
+ omOfferingInstService.batchInsertInstV2(data);
+ // 非分区表,insert into values (),()
+ // omOfferingInstService.batchInsertInstV3(data);
+ return "success";
+ }
+
+ @RequestMapping("/index/testCopy")
+ @ResponseBody
+ public String testCopyTable() throws SQLException, ClassNotFoundException {
+ return omOfferingInstService.testCopyTable();
+ }
+}
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/controller/StudentController.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/controller/StudentController.java
new file mode 100644
index 0000000000000000000000000000000000000000..525c5970bc5f9684aa86a99c9a404b9c26990673
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/controller/StudentController.java
@@ -0,0 +1,147 @@
+package io.mogdb.springmvc.mybatis.controller;
+
+import com.alibaba.fastjson.JSONObject;
+import io.mogdb.springmvc.mybatis.entity.StudentEntity;
+import io.mogdb.springmvc.mybatis.service.StudentService;
+import com.github.pagehelper.PageInfo;
+import org.apache.commons.lang3.StringUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Controller;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.ResponseBody;
+import org.springframework.web.servlet.ModelAndView;
+
+import java.util.List;
+
+
+@Controller
+@RequestMapping("/student")
+public class StudentController {
+ private static final Logger logger = LoggerFactory.getLogger(StudentController.class);
+
+ @Autowired
+ private StudentService studentService;
+
+ @RequestMapping("/testBatch")
+ @ResponseBody
+ public String testAddTestBatchRecord() {
+ int rows = studentService.addTestBatchRecord();
+ if (rows > 0) {
+ return "插入 test_batch 成功";
+ } else {
+ return "插入 test_batch 失败";
+ }
+ }
+
+ @RequestMapping("/findAll")
+ public ModelAndView findAll() {
+ List entities = studentService.findAllStudent();
+ ModelAndView modelAndView = new ModelAndView();
+ modelAndView.setViewName("student");
+ modelAndView.addObject("list", entities);
+ logger.info("size={}", entities.size());
+ return modelAndView;
+ }
+
+ @RequestMapping("/findPage")
+ @ResponseBody
+ public PageInfo findPage() {
+ PageInfo pageInfo = studentService.findPageStudent();
+ logger.info("size={}", pageInfo.getSize());
+ return pageInfo;
+ }
+
+ @ResponseBody
+ @RequestMapping("/getList")
+ public String getStudentList() {
+ List entities = studentService.findAllStudent();
+ String studentList = JSONObject.toJSONString(entities);
+ return studentList;
+ }
+
+ public static void main(String[] args) {
+ System.err.println((int) (Math.random() * 100));
+ }
+
+ @ResponseBody
+ @RequestMapping("/addRecord")
+ public String addRecord(StudentEntity studentEntity) {
+ if (studentEntity == null || studentEntity.getClassId() < 1) {
+ int classId = (int) (Math.random() * 100);
+ studentEntity = new StudentEntity();
+ studentEntity.setName("zp" + classId);
+ studentEntity.setClassId(classId);
+ studentEntity.setStatus(0);
+ } else if (StringUtils.isBlank(studentEntity.getName())) {
+ int classId = studentEntity.getClassId();
+ studentEntity.setName("zp" + classId);
+ }
+ studentService.insertStudent(studentEntity);
+ String result = "insertStudent result={" + studentEntity.getId() + "}";
+ return result;
+ }
+
+ @ResponseBody
+ @RequestMapping("/deleteRecord")
+ public String deleteRecord(StudentEntity studentEntity) {
+ if (studentEntity == null || studentEntity.getId() < 1) {
+ studentEntity.setId(-1);
+ }
+ int count = studentService.deleteStudent(studentEntity.getId());
+ if (count > 0) {
+ return "deleteStudent result={" + studentEntity.getId() + "}";
+ } else {
+ return "数据不存在,删除失败。";
+ }
+ }
+
+ @ResponseBody
+ @RequestMapping("/updateRecord")
+ public String updateRecord(StudentEntity studentEntity) {
+ if (studentEntity == null || studentEntity.getId() < 1) {
+ studentEntity.setId(-1);
+ }
+ int count = studentService.updateStudent(studentEntity);
+ if (count > 0) {
+ return "updateStudent result={" + studentEntity.getId() + "}";
+ } else {
+ return "数据不存在,更新失败。";
+ }
+ }
+
+ @ResponseBody
+ @RequestMapping("/updateRecordV2")
+ public String updateRecordV2(StudentEntity studentEntity) {
+ StudentEntity stu1 = studentService.findAllStudent().stream().findFirst().get();
+ int count = studentService.updateStudent(stu1);
+ studentService.deleteStudent(stu1.getId());
+ if (count > 0) {
+ return "updateStudent result={" + studentEntity.getId() + "}";
+ } else {
+ return "数据不存在,更新失败。";
+ }
+ }
+
+ @ResponseBody
+ @RequestMapping("/updateRecordV3")
+ public String updateRecordV3(StudentEntity studentEntity) {
+ studentService.testV3(studentEntity);
+ return "success";
+ }
+
+ @ResponseBody
+ @RequestMapping("/updateRecordV4")
+ public String updateRecordV4(StudentEntity studentEntity) {
+ studentService.insertStudentV2(studentEntity);
+ return "success";
+ }
+
+ @ResponseBody
+ @RequestMapping("/testV5")
+ public String testV5(StudentEntity studentEntity) {
+ studentService.testV5(studentEntity);
+ return "success";
+ }
+}
\ No newline at end of file
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/dao/OmOfferingInstDAO.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/dao/OmOfferingInstDAO.java
new file mode 100644
index 0000000000000000000000000000000000000000..8913c3c8e72d9de310ac47e4279bfc0885ec484d
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/dao/OmOfferingInstDAO.java
@@ -0,0 +1,12 @@
+package io.mogdb.springmvc.mybatis.dao;
+
+import org.springframework.stereotype.Repository;
+
+import java.util.Map;
+
+@Repository
+public interface OmOfferingInstDAO {
+ int batchInsert(Map params);
+
+ int executeCMD();
+}
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/dao/StudentDAO.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/dao/StudentDAO.java
new file mode 100644
index 0000000000000000000000000000000000000000..8c0aeacd43c98bf8adb0e6d4c3b26b50c7ba6bd2
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/dao/StudentDAO.java
@@ -0,0 +1,32 @@
+package io.mogdb.springmvc.mybatis.dao;
+
+import io.mogdb.springmvc.mybatis.entity.StudentEntity;
+import org.apache.ibatis.annotations.Param;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+import java.util.Map;
+
+@Repository
+public interface StudentDAO {
+
+ Integer insertStudent(@Param("studentEntity") StudentEntity studentEntity);
+
+ Integer updateStudent(@Param("studentEntity") StudentEntity studentEntity);
+
+ Integer deleteStudent(@Param("id") int id);
+
+ List findAllValidStudent();
+
+ StudentEntity findStudentById(@Param("id") int id);
+
+ int batchInsert(Map data);
+
+ int batchInsertV2(Map data);
+
+ int executeCMD();
+
+ int addTestRBatchRecord(@Param("col1") int col1, @Param("col2") String col2);
+
+ int addTestRBatchRecordV2(Map data);
+}
\ No newline at end of file
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/entity/StudentEntity.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/entity/StudentEntity.java
new file mode 100644
index 0000000000000000000000000000000000000000..f8b137febad58c8340d60e5a0f0905acb11f2f2d
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/entity/StudentEntity.java
@@ -0,0 +1,67 @@
+package io.mogdb.springmvc.mybatis.entity;
+
+import java.io.Serializable;
+import java.util.Date;
+
+public class StudentEntity implements Serializable {
+ private static final long serialVersionUID = 7475710140661551551L;
+
+ private int id; //学号
+ private String name; //姓名
+ private int classId; //班级
+ private int status; //是否有效(1:有效,-1:无效)
+ private Date addTime; //添加时间
+ private Date updateTime; //更新时间
+
+ public static long getSerialVersionUID() {
+ return serialVersionUID;
+ }
+
+ public int getId() {
+ return id;
+ }
+
+ public void setId(int id) {
+ this.id = id;
+ }
+
+ public String getName() {
+ return name;
+ }
+
+ public void setName(String name) {
+ this.name = name;
+ }
+
+ public int getClassId() {
+ return classId;
+ }
+
+ public void setClassId(int classId) {
+ this.classId = classId;
+ }
+
+ public int getStatus() {
+ return status;
+ }
+
+ public void setStatus(int status) {
+ this.status = status;
+ }
+
+ public Date getAddTime() {
+ return addTime;
+ }
+
+ public void setAddTime(Date addTime) {
+ this.addTime = addTime;
+ }
+
+ public Date getUpdateTime() {
+ return updateTime;
+ }
+
+ public void setUpdateTime(Date updateTime) {
+ this.updateTime = updateTime;
+ }
+}
\ No newline at end of file
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/MyStudentService.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/MyStudentService.java
new file mode 100644
index 0000000000000000000000000000000000000000..dcb03321ac6b7ac2f953ea5dd9665c4073a179b7
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/MyStudentService.java
@@ -0,0 +1,11 @@
+package io.mogdb.springmvc.mybatis.service;
+
+import io.mogdb.springmvc.mybatis.entity.StudentEntity;
+import org.springframework.stereotype.Component;
+
+@Component
+public interface MyStudentService {
+ String testTs(StudentEntity studentEntity);
+
+ String updateV2(StudentEntity studentEntity);
+}
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/OmOfferingInstService.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/OmOfferingInstService.java
new file mode 100644
index 0000000000000000000000000000000000000000..834937d5898d09c37937d679a606ead0d4cafc8d
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/OmOfferingInstService.java
@@ -0,0 +1,17 @@
+package io.mogdb.springmvc.mybatis.service;
+
+import org.springframework.stereotype.Component;
+
+import java.sql.SQLException;
+import java.util.Map;
+
+@Component
+public interface OmOfferingInstService {
+ int batchInsertInst(Map data);
+
+ int batchInsertInstV2(Map data);
+
+ int batchInsertInstV3(Map data);
+
+ String testCopyTable() throws ClassNotFoundException, SQLException;
+}
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/StudentService.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/StudentService.java
new file mode 100644
index 0000000000000000000000000000000000000000..03c9af9df858ae4a3cdd48672000dabeb9d6dbf2
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/StudentService.java
@@ -0,0 +1,30 @@
+package io.mogdb.springmvc.mybatis.service;
+
+import io.mogdb.springmvc.mybatis.entity.StudentEntity;
+import com.github.pagehelper.PageInfo;
+import org.springframework.stereotype.Component;
+
+import java.util.List;
+
+@Component
+public interface StudentService {
+ Integer insertStudent(StudentEntity studentEntity);
+
+ Integer updateStudent(StudentEntity studentEntity);
+
+ Integer deleteStudent(int id);
+
+ List findAllStudent();
+
+ PageInfo findPageStudent();
+
+ StudentEntity findStudentById(int id);
+
+ String testV3(StudentEntity studentEntity);
+
+ String testV5(StudentEntity studentEntity);
+
+ String insertStudentV2(StudentEntity studentEntity);
+
+ int addTestBatchRecord();
+}
\ No newline at end of file
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/impl/MyStudentServiceImpl.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/impl/MyStudentServiceImpl.java
new file mode 100644
index 0000000000000000000000000000000000000000..18b9917f07234a14603659d9eece6ef9906b7ae9
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/impl/MyStudentServiceImpl.java
@@ -0,0 +1,29 @@
+package io.mogdb.springmvc.mybatis.service.impl;
+
+import io.mogdb.springmvc.mybatis.entity.StudentEntity;
+import io.mogdb.springmvc.mybatis.service.MyStudentService;
+import io.mogdb.springmvc.mybatis.service.StudentService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+@Service
+public class MyStudentServiceImpl implements MyStudentService {
+ @Autowired
+ private StudentService studentService;
+
+ @Override
+ public String testTs(StudentEntity studentEntity) {
+ studentEntity = studentService.findAllStudent().stream().findFirst().get();
+ studentService.updateStudent(studentEntity);
+ studentService.deleteStudent(studentEntity.getId());
+ return "success";
+ }
+
+ @Override
+ public String updateV2(StudentEntity studentEntity) {
+ studentEntity = studentService.findAllStudent().stream().findFirst().get();
+ studentService.updateStudent(studentEntity);
+ studentService.deleteStudent(studentEntity.getId());
+ return "success";
+ }
+}
diff --git a/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/impl/OmOfferingInstServiceImpl.java b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/impl/OmOfferingInstServiceImpl.java
new file mode 100644
index 0000000000000000000000000000000000000000..f33bcc1906aa4d369e4df181ce45243288a327c5
--- /dev/null
+++ b/mogdb-springmvc-mybatis-demo/src/main/java/io/mogdb/springmvc/mybatis/service/impl/OmOfferingInstServiceImpl.java
@@ -0,0 +1,182 @@
+package io.mogdb.springmvc.mybatis.service.impl;
+
+import io.mogdb.springmvc.mybatis.dao.OmOfferingInstDAO;
+import io.mogdb.springmvc.mybatis.dao.StudentDAO;
+import io.mogdb.springmvc.mybatis.service.OmOfferingInstService;
+import org.postgresql.copy.CopyManager;
+import org.postgresql.core.BaseConnection;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.sql.Connection;
+import java.sql.DriverManager;
+import java.sql.SQLException;
+import java.util.*;
+import java.util.stream.IntStream;
+
+@Service
+public class OmOfferingInstServiceImpl implements OmOfferingInstService {
+ @Autowired
+ private OmOfferingInstDAO omOfferingInstDAO;
+
+ @Autowired
+ private StudentDAO studentDAO;
+
+ @Override
+ public int batchInsertInst(Map data) {
+ List