@Override
    public List<Order> load(Criteria criteria, GenericLoadQuery loadGeneric, Connection conn) throws DaoQueryException {
        int pageSize = 50;

        List paramList = new ArrayList<>();
        StringBuilder sb = new StringBuilder(WHERE);
        String queryStr = new QueryMapper() {
            @Override
            public String mapQuery() {
                Appender.append(DAO_ID_ORDER, DB_ORDER_ID_ORDER, criteria, paramList, sb, AND);
                Appender.append(DAO_ID_USER, DB_ORDER_ID_USER, criteria, paramList, sb, AND);
                Appender.append(DAO_ID_TOUR, DB_ORDER_ID_TOUR, criteria, paramList, sb, AND);
                Appender.append(DAO_ORDER_SEATS, DB_ORDER_SEATS, criteria, paramList, sb, AND);
                Appender.append(DAO_ORDER_CURR_PRICE, DB_ORDER_CURR_PRICE, criteria, paramList, sb, AND);
                Appender.append(DAO_ORDER_CURR_DISCOUNT, DB_ORDER_CURR_DISCOUNT, criteria, paramList, sb, AND);
                Appender.append(DAO_ORDER_USER_DISCOUNT, DB_ORDER_USER_DISCOUNT, criteria, paramList, sb, AND);
                Appender.append(DAO_ORDER_FINAL_PRICE, DB_ORDER_FINAL_PRICE, criteria, paramList, sb, AND);
                Appender.append(DAO_ORDER_DATE, DB_ORDER_DATE, criteria, paramList, sb, AND);
                Appender.append(DAO_ORDER_STATUS, DB_ORDER_STATUS, criteria, paramList, sb, AND);
                if (paramList.isEmpty()) {
                    return LOAD_QUERY;
                } else {
                    return sb.insert(0, LOAD_QUERY).toString();
                }
            }
        }.mapQuery();

        try {
            return loadGeneric.sendQuery(queryStr, paramList.toArray(), pageSize, conn, (ResultSet rs, int rowNum) -> {
                Order bean = new Order();
                bean.setIdOrder(rs.getInt(DB_ORDER_ID_ORDER));
                bean.setUser(new User(rs.getInt(DB_ORDER_ID_USER)));
                bean.setTour(new Tour(rs.getInt(DB_ORDER_ID_TOUR)));
                bean.setSeats(rs.getInt(DB_ORDER_SEATS));
                bean.setCurrentPrice(rs.getFloat(DB_ORDER_CURR_PRICE));
                bean.setCurrentDiscount(rs.getInt(DB_ORDER_CURR_DISCOUNT));
                bean.setCurrentUserDiscount(rs.getInt(DB_ORDER_USER_DISCOUNT));
                bean.setFinalPrice(rs.getFloat(DB_ORDER_FINAL_PRICE));
                bean.setOrderDate(rs.getDate(DB_ORDER_DATE));
                bean.setStatus(rs.getShort(DB_ORDER_STATUS));
                return bean;
            });
        } catch (DaoException ex) {
             throw new DaoQueryException(ERR_ORDER_LOAD, ex);
        }
    }