Package com.founder.fix.fixflow.core.db.pagination

Examples of com.founder.fix.fixflow.core.db.pagination.Pagination


    this.connection = connection;
    pageination = initDialet(connection);
  }
 
  public static Pagination initDialet(Connection connection){
    Pagination pageination = null;
    try{
      String dbms = connection.getMetaData().getDatabaseProductName();
      if ( dbms == null || dbms.equals("") ){
        pageination = (Pagination)Class.forName("com.founder.fix.fixflow.expand.database.pagination.OraclePaginationImpl").newInstance();
      }else if ( dbms.equals("Oracle") ){
View Full Code Here


    return true;
  }
 
  private String getInsertSqlString(String tableId,String whereSql){
   
    Pagination pagination = Context.getProcessEngineConfiguration().getDbConfig().getPagination();
    String tableName = QueryTableUtil.getDefaultTableName(tableId);
    String archiveTableName = QueryTableUtil.getArchiveTableName(tableId);
    String columnString = QueryTableUtil.getColumnStringWithOutArchiveTime(tableId);
    String insertSqlString = "insert into "+archiveTableName+" (" + columnString+",ARCHIVE_TIME) select "+columnString+","+pagination.getCurrentDateSql()+" from "+tableName +" E where " + whereSql;
    return insertSqlString;
  }
View Full Code Here

      }
    }
   
    if(page!=null)
    {
      Pagination pagination=Context.getProcessEngineConfiguration().getDbConfig().getPagination();
      sqlString=pagination.getPaginationSql(sqlString, page.getFirstResult(), page.getMaxResults(), "*",orderByString);
    }else{
      if (eventSubscriptionQuery.getOrderBy() != null) {
        sqlString = sqlString + " order by " + eventSubscriptionQuery.getOrderBy().toString();
      }
    }
View Full Code Here

        orderByString = orderByString + " order by " + tokenQuery.getOrderBy().toString().substring(2);
      }
    }
   
    if(page!=null){
      Pagination pagination=Context.getProcessEngineConfiguration().getDbConfig().getPagination();
      sqlString=pagination.getPaginationSql(sqlString, page.getFirstResult(), page.getMaxResults(), "*",orderByString);
    }else{
      if (tokenQuery.getOrderBy() != null) {
        sqlString = sqlString + " order by "+tokenQuery.getOrderBy().toString();
        }
    }
View Full Code Here

    //pObjects.add(MailStatus.COMPLETE.toString());
    //pObjects.add(MailStatus.FAILURE.toString());
    pObjects.add(MailStatus.NOSEND.toString());
    SqlCommand sqlCommand = new SqlCommand(Context.getDbConnection());
   
    Pagination pagination = Context.getProcessEngineConfiguration().getDbConfig().getPagination();
   
   
   
   
    String sqlText=pagination.getPaginationSql("SELECT * FROM FIXFLOW_MAIL WHERE MAIL_STATUS=?", 1, 10, "*", null);
   
    List<Map<String, Object>> dataList = sqlCommand.queryForList(sqlText, pObjects);
   
    for (Map<String, Object> mapData : dataList) {

View Full Code Here

      }
    }
   
   
    if (page != null) {
      Pagination pagination = Context.getProcessEngineConfiguration().getDbConfig().getPagination();
      sqlString = pagination.getPaginationSql(sqlString, page.getFirstResult(), page.getMaxResults(), "*",orderByString);
    }
    else{
      if (processInstanceQuery.getOrderBy() != null) {
        sqlString = sqlString + " order by " + processInstanceQuery.getOrderBy().toString();
        }
View Full Code Here

    sql += whereSql;
    countSql += whereSql;
   
    int count = Integer.parseInt(sqlCommand.queryForValue(countSql).toString());
    if (page != null) {
      Pagination pagination = Context.getProcessEngineConfiguration().getDbConfig().getPagination();
      sql = pagination.getPaginationSql(sql, page.getFirstResult(), page.getMaxResults(), "*",null);
    }
    List<Map<String, Object>> dataObj = sqlCommand.queryForList(sql, null);
   
    for(int i= 0;i<dataObj.size();i++){
      if (dataObj.get(i).get(userIdField) != null) {
View Full Code Here

      }
      sql += whereSql;
      countSql += whereSql;
     
      if (page != null) {
        Pagination pagination = Context.getProcessEngineConfiguration().getDbConfig().getPagination();
        sql = pagination.getPaginationSql(sql, page.getFirstResult(), page.getMaxResults(), "*",null);
      }
      List<Map<String, Object>> dataObj = sqlCommand.queryForList(sql, null);
      int count = Integer.parseInt(sqlCommand.queryForValue(countSql).toString());
      for(int i = 0;i<dataObj.size();i++){
        if (dataObj.get(0).get(groupIdField) != null) {
View Full Code Here

    return null;
  }
 
  private String getInsertSqlString(String tableId,String whereSql){
   
    Pagination pagination = Context.getProcessEngineConfiguration().getDbConfig().getPagination();
    String tableName = QueryTableUtil.getDefaultTableName(tableId);
    String archiveTableName = QueryTableUtil.getArchiveTableName(tableId);
    String columnString = QueryTableUtil.getColumnStringWithOutArchiveTime(tableId);
    String insertSqlString = "insert into "+archiveTableName+" (" + columnString+",ARCHIVE_TIME) select "+columnString+","+pagination.getCurrentDateSql()+" from "+tableName +"  where " + whereSql;
    return insertSqlString;
  }
View Full Code Here

  protected void initSqlServerDbConfig() {

    DataBase dataBase = this.selectedDatabase;

    // OraclePaginationImpl
    Pagination pagination = (Pagination) ReflectUtil.instantiate(dataBase.getPaginationImpl());
    DbConfig dbConfig = new DbConfig();
    dbConfig.setDbType(DbType.SQLSERVER);
    dbConfig.setPagination(pagination);
    dbConfig.setKeyword("?");
View Full Code Here

TOP

Related Classes of com.founder.fix.fixflow.core.db.pagination.Pagination

Copyright © 2018 www.massapicom. 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.