Skip to main content
Version: 4.5

Interface: OrderBy<TRecord, TResult>#

knex.Knex.OrderBy

Type parameters#

NameDefault
TRecordany
TResultunknown[]

Callable#

OrderBy(columnName: QueryBuilder<any, any> | keyof TRecord, order?: asc | desc): QueryBuilder<TRecord, TResult>

Parameters:#

NameType
columnNameQueryBuilder<any, any> | keyof TRecord
order?asc | desc

Returns: QueryBuilder<TRecord, TResult>

Defined in: node_modules/knex/types/index.d.ts:1369

OrderBy(columnName: string | QueryBuilder<any, any>, order?: string): QueryBuilder<TRecord, TResult>

Parameters:#

NameType
columnNamestring | QueryBuilder<any, any>
order?string

Returns: QueryBuilder<TRecord, TResult>

Defined in: node_modules/knex/types/index.d.ts:1373

OrderBy(columnDefs: (keyof TRecord | Readonly<{ column: QueryBuilder<any, any> | keyof TRecord ; order?: asc | desc }>)[]): QueryBuilder<TRecord, TResult>

Parameters:#

NameType
columnDefs(keyof TRecord | Readonly<{ column: QueryBuilder<any, any> | keyof TRecord ; order?: asc | desc }>)[]

Returns: QueryBuilder<TRecord, TResult>

Defined in: node_modules/knex/types/index.d.ts:1374

OrderBy(columnDefs: (string | Readonly<{ column: string | QueryBuilder<any, any> ; order?: string }>)[]): QueryBuilder<TRecord, TResult>

Parameters:#

NameType
columnDefs(string | Readonly<{ column: string | QueryBuilder<any, any> ; order?: string }>)[]

Returns: QueryBuilder<TRecord, TResult>

Defined in: node_modules/knex/types/index.d.ts:1382

Last updated on by Martin Adámek