Package com.dotmarketing.common.db

Examples of com.dotmarketing.common.db.DotConnect.executeStatement()


      dc.addParam(uuid);
      dc.addParam(workflowTaskId);
      dc.addParam(fileInode);
      dc.loadResult();
      }
    dc.executeStatement(delete_task_file_relations);
  }
    private void workflowCommentChanges() throws SQLException, DotDataException{
      DotConnect dc = new DotConnect();
      String dropInode = "";
      if (DbConnectionFactory.isMySql()){
View Full Code Here


    String deleteFromTree = "Delete from tree where parent in(select id from workflow_task) and child in(select id from workflow_comment)";
   
    List<String> queries = SQLUtil.tokenize(dropInode+addWorkFlowCommentFK);
    for(String query :queries){
        try {
            dc.executeStatement(query);
        } catch(Exception ex) {
            Logger.warn(this, ex.getMessage());
        }
    }
    dc.setSQL(workflowtask_workflowcomment_relations);
View Full Code Here

        dc.setSQL("UPDATE workflow_comment set workflowtask_id = ? where id = ?");
      dc.addParam(workflowTaskId);
      dc.addParam(workflowCommentId);
      dc.loadResult();
      }
      dc.executeStatement(deleteFromTree);
  }
    private void workflowHistoryChanges() throws SQLException, DotDataException{
      String dropInode = "";
      DotConnect dc = new DotConnect();
      if (DbConnectionFactory.isMySql()){
View Full Code Here

    String deleteFromTree = "Delete from tree where parent in(select id from workflow_task) and child in(select id from workflow_history)";
   
    List<String> queries = SQLUtil.tokenize(dropInode+addWorkFlowHistoryFK);
    for(String query :queries){
        try {
            dc.executeStatement(query);
        } catch(Exception ex) {
            Logger.warn(this, ex.getMessage());
        }
    }
   
View Full Code Here

      dc.addParam(workflowTaskInode);
      dc.addParam(workflowHistoryInode);
      dc.loadResult();
      }
     
      dc.executeStatement(deleteFromTree);
    }
    private void dropWorkFlowTaskIndexes() throws SQLException{
      String indexes = "";
      DotConnect dc = new DotConnect();
      if(DbConnectionFactory.isOracle()||
View Full Code Here

                  "drop index workflow_task.idx_workflow_4;" +
                  "drop index workflow_task.idx_workflow_5;";
      }
      List<String> indexList = SQLUtil.tokenize(indexes);
      for(String index:indexList){
        dc.executeStatement(index);
      }
    }
    private void addWorkFlowTaskIndexes() throws SQLException{
      DotConnect dc = new DotConnect();
      if(DbConnectionFactory.isOracle()||
View Full Code Here

    private void addWorkFlowTaskIndexes() throws SQLException{
      DotConnect dc = new DotConnect();
      if(DbConnectionFactory.isOracle()||
                DbConnectionFactory.isPostgres() ||
                DbConnectionFactory.isMsSql()){
        dc.executeStatement("create index idx_workflow_4 on workflow_task (webasset)");
        dc.executeStatement("create index idx_workflow_5 on workflow_task (created_by)");
        dc.executeStatement("create index idx_workflow_2 on workflow_task (belongs_to)");
        dc.executeStatement("create index idx_workflow_3 on workflow_task (status)");
        dc.executeStatement("create index idx_workflow_1 on workflow_task (assigned_to)");
      }
View Full Code Here

      DotConnect dc = new DotConnect();
      if(DbConnectionFactory.isOracle()||
                DbConnectionFactory.isPostgres() ||
                DbConnectionFactory.isMsSql()){
        dc.executeStatement("create index idx_workflow_4 on workflow_task (webasset)");
        dc.executeStatement("create index idx_workflow_5 on workflow_task (created_by)");
        dc.executeStatement("create index idx_workflow_2 on workflow_task (belongs_to)");
        dc.executeStatement("create index idx_workflow_3 on workflow_task (status)");
        dc.executeStatement("create index idx_workflow_1 on workflow_task (assigned_to)");
      }
    }
View Full Code Here

      if(DbConnectionFactory.isOracle()||
                DbConnectionFactory.isPostgres() ||
                DbConnectionFactory.isMsSql()){
        dc.executeStatement("create index idx_workflow_4 on workflow_task (webasset)");
        dc.executeStatement("create index idx_workflow_5 on workflow_task (created_by)");
        dc.executeStatement("create index idx_workflow_2 on workflow_task (belongs_to)");
        dc.executeStatement("create index idx_workflow_3 on workflow_task (status)");
        dc.executeStatement("create index idx_workflow_1 on workflow_task (assigned_to)");
      }
    }
View Full Code Here

                DbConnectionFactory.isPostgres() ||
                DbConnectionFactory.isMsSql()){
        dc.executeStatement("create index idx_workflow_4 on workflow_task (webasset)");
        dc.executeStatement("create index idx_workflow_5 on workflow_task (created_by)");
        dc.executeStatement("create index idx_workflow_2 on workflow_task (belongs_to)");
        dc.executeStatement("create index idx_workflow_3 on workflow_task (status)");
        dc.executeStatement("create index idx_workflow_1 on workflow_task (assigned_to)");
      }
    }

  public void executeUpgrade() throws DotDataException, DotRuntimeException {
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.