Package java.sql

Examples of java.sql.Connection.prepareCall()


    Connection conn = null;
    CallableStatement cStmt = null;
    int id = -1;
    try {
      conn = dataSource.getConnection();
      cStmt = conn.prepareCall("{call createTagProperty(?,?,?,?,?,?)}");
      cStmt.setString(1,tagPrpt.getName());
      cStmt.setString(2,tagPrpt.getNamespacePrefix());
      cStmt.setString(3,tagPrpt.getDescription());
      cStmt.setString(4,tagPrpt.getPropertyType());
      cStmt.setInt(5,tagPrpt.getCardinality());
View Full Code Here


    Connection conn = null;
    CallableStatement cstmt = null;
    boolean isOkay = true;
    try {
      conn = dataSource.getConnection();
      cstmt = conn.prepareCall("call deleteRDFTypeAssertion(?,?,?)");
      int userId = user.getId();
      int subjectTagId = subjectTag.getId();
      for(int i = 0; i < objectTag.length; i++){
        cstmt.setInt(1,userId);
        cstmt.setInt(2,subjectTagId);
View Full Code Here

    Connection conn = null;
    CallableStatement cstmt = null;
    boolean isOkay = true;
    try {
      conn = dataSource.getConnection();
      cstmt = conn.prepareCall("call deleteSKOSBroaderAssertion(?,?,?)");
      int userId = user.getId();
      int subjectTagId = subjectTag.getId();
      for(int i = 0; i < objectTag.length; i++){
        cstmt.setInt(1,userId);
        cstmt.setInt(2,subjectTagId);
View Full Code Here

    Connection conn = null;
    CallableStatement cstmt = null;
    boolean isOkay = true;
    try {
      conn = dataSource.getConnection();
      cstmt = conn.prepareCall("call deleteSKOSNarrowerAssertion(?,?,?)");
      int userId = user.getId();
      int subjectTagId = subjectTag.getId();
      for(int i = 0; i < objectTag.length; i++){
        cstmt.setInt(1,userId);
        cstmt.setInt(2,subjectTagId);
View Full Code Here

    Connection conn = null;
    CallableStatement cstmt = null;
    boolean isOkay = true;
    try {
      conn = dataSource.getConnection();
      cstmt = conn.prepareCall("call deleteSKOSRelatedAssertion(?,?,?)");
      int userId = user.getId();
      int subjectTagId = subjectTag.getId();
      for(int i = 0; i < objectTag.length; i++){
        cstmt.setInt(1,userId);
        cstmt.setInt(2,subjectTagId);
View Full Code Here

    CallableStatement cStmt = null;
    //int id = -1;
    boolean isOkay = true;
    try {
      conn = dataSource.getConnection();
      cStmt = conn.prepareCall("{call createTagAssertionNoOutput(?,?,?,?)}");
      for(TagAssertion assertion : asrt){       
        cStmt.setInt(1,assertion.getSubject().getId());
        cStmt.setInt(2,assertion.getProperty().getId());
        cStmt.setInt(3,assertion.getObject().getId());
        cStmt.setInt(4,assertion.getUser().getId());       
View Full Code Here

    Connection conn = null;
    CallableStatement cstmt = null;
    boolean isOkay = true;
    try {
      conn = dataSource.getConnection();
      cstmt = conn.prepareCall("call deleteRDFTypeClassAssertion(?,?)");
      cstmt.setInt(1,user.getId());
      cstmt.setInt(2,classTag.getId());     
      cstmt.execute();
    } catch (SQLException e) {
      logger.fatal(e);
View Full Code Here

    Connection conn = null;
    CallableStatement cstmt = null;
    boolean isOkay = true;
    try {
      conn = dataSource.getConnection();
      cstmt = conn.prepareCall("call deleteRDFTypeAssertion(?,?,?)");
      int userId = user.getId();
      int objectTagId = objectTag.getId();
      for(int i = 0; i < subjectTag.length; i++){
        cstmt.setInt(1,userId);
        cstmt.setInt(2,subjectTag[i].getId());
View Full Code Here

    Connection conn = null;
    try {
      if (this.conn==null) conn = getConn(); else conn = this.conn;

      // logically delete record in SCH01...
      pstmt = conn.prepareCall(
         "update SCH01_EMPLOYEES set ENABLED='N',LAST_UPDATE_USER=?,LAST_UPDATE_DATE=?  where COMPANY_CODE_SYS01='"+vo.getCompanyCodeSys01REG04()+"' and PROGRESSIVE_REG04="+vo.getProgressiveREG04()
      );
      pstmt.setString(1,username);
      pstmt.setTimestamp(2,new java.sql.Timestamp(System.currentTimeMillis()));
      pstmt.execute();
View Full Code Here

      pstmt.setTimestamp(2,new java.sql.Timestamp(System.currentTimeMillis()));
      pstmt.execute();
      pstmt.close();

      // logically delete record in REG04...
      pstmt = conn.prepareCall(
         "update REG04_SUBJECTS set ENABLED='N',LAST_UPDATE_USER=?,LAST_UPDATE_DATE=?  where COMPANY_CODE_SYS01='"+vo.getCompanyCodeSys01REG04()+"' and PROGRESSIVE="+vo.getProgressiveREG04()
      );
      pstmt.setString(1,username);
      pstmt.setTimestamp(2,new java.sql.Timestamp(System.currentTimeMillis()));
      pstmt.execute();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.