public class SqlPagingQueryUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static String |
buildSortClause(AbstractSqlPagingQueryProvider provider)
Generates ORDER BY attributes based on the sort keys.
|
static String |
buildSortClause(Map<String,Order> sortKeys)
Generates ORDER BY attributes based on the sort keys.
|
static void |
buildWhereClause(AbstractSqlPagingQueryProvider provider,
boolean remainingPageQuery,
StringBuilder sql)
Generates WHERE clause for queries that require sub selects.
|
static String |
generateLimitJumpToQuery(AbstractSqlPagingQueryProvider provider,
String limitClause)
Generate SQL query string using a LIMIT clause
|
static String |
generateTopJumpToQuery(AbstractSqlPagingQueryProvider provider,
String topClause)
Generate SQL query string using a TOP clause
|
static String |
generateTopSqlQuery(AbstractSqlPagingQueryProvider provider,
boolean remainingPageQuery,
String topClause)
Generate SQL query string using a TOP clause
|
public static String generateLimitJumpToQuery(AbstractSqlPagingQueryProvider provider, String limitClause)
provider - AbstractSqlPagingQueryProvider providing the implementation
specificslimitClause - the implementation specific top clause to be usedpublic static String generateTopJumpToQuery(AbstractSqlPagingQueryProvider provider, String topClause)
provider - AbstractSqlPagingQueryProvider providing the implementation
specificstopClause - the implementation specific top clause to be usedpublic static void buildWhereClause(AbstractSqlPagingQueryProvider provider, boolean remainingPageQuery, StringBuilder sql)
provider - the paging query provider that will provide the base where clauseremainingPageQuery - whether there is a page querysql - the sql to append the WHERE clausepublic static String generateTopSqlQuery(AbstractSqlPagingQueryProvider provider, boolean remainingPageQuery, String topClause)
provider - AbstractSqlPagingQueryProvider providing the
implementation specificsremainingPageQuery - is this query for the remaining pages (true) as
opposed to the first page (false)topClause - the implementation specific top clause to be usedpublic static String buildSortClause(AbstractSqlPagingQueryProvider provider)
provider - AbstractSqlPagingQueryProvider providing the implementation
specificsCopyright © 2021 Pivotal Software, Inc.. All rights reserved.