Class QueryOrderPart
java.lang.Object
com.northconcepts.datapipeline.jdbc.sql.SqlPart
com.northconcepts.datapipeline.jdbc.sql.select.QueryPart
com.northconcepts.datapipeline.jdbc.sql.select.QueryOrderPart
One ORDER BY entry: a field, its direction and optional null placement.
-
Constructor Summary
ConstructorsConstructorDescriptionQueryOrderPart(String field, boolean ascending) QueryOrderPart(String field, boolean ascending, Boolean nullsFirst) -
Method Summary
Modifier and TypeMethodDescriptionvoidcollectSqlFragment(CodeWriter writer) Writes this part's SQL to the writer; used bySqlPart.getSqlFragment()and by enclosing parts.getField()Indicates if nulls sort first (NULLS FIRST) or last (NULLS LAST);null, the default, adds neither.booleanIndicates if the field sorts in ascending order; otherwiseDESCis added (default is false).setAscending(boolean ascending) Indicates if the field sorts in ascending order; otherwiseDESCis added (default is false).setNullsFirst(Boolean nullsFirst) Indicates if nulls sort first (NULLS FIRST) or last (NULLS LAST);null, the default, adds neither.Methods inherited from class com.northconcepts.datapipeline.jdbc.sql.SqlPart
collectParameterValues, getParameterValues, getSqlFragment, isPretty, printSqlParts, setPretty, toString
-
Constructor Details
-
QueryOrderPart
public QueryOrderPart() -
QueryOrderPart
-
QueryOrderPart
-
-
Method Details
-
getField
-
setField
-
isAscending
public boolean isAscending()Indicates if the field sorts in ascending order; otherwiseDESCis added (default is false). -
setAscending
Indicates if the field sorts in ascending order; otherwiseDESCis added (default is false). -
getNullsFirst
Indicates if nulls sort first (NULLS FIRST) or last (NULLS LAST);null, the default, adds neither. -
setNullsFirst
Indicates if nulls sort first (NULLS FIRST) or last (NULLS LAST);null, the default, adds neither. -
collectSqlFragment
Description copied from class:SqlPartWrites this part's SQL to the writer; used bySqlPart.getSqlFragment()and by enclosing parts.- Specified by:
collectSqlFragmentin classSqlPart
-