MCPcopy
hub / github.com/ent/ent / OrderExpr

Method OrderExpr

dialect/sql/builder.go:2461–2466  ·  view source on GitHub ↗

OrderExpr appends the `ORDER BY` clause to the `SELECT` statement with custom list of expressions.

(exprs ...Querier)

Source from the content-addressed store, hash-verified

2459// OrderExpr appends the `ORDER BY` clause to the `SELECT`
2460// statement with custom list of expressions.
2461func (s *Selector) OrderExpr(exprs ...Querier) *Selector {
2462 for i := range exprs {
2463 s.order = append(s.order, exprs[i])
2464 }
2465 return s
2466}
2467
2468// OrderExprFunc appends the `ORDER BY` expression that evaluates
2469// the given function.

Callers 10

OrderExprFuncMethod · 0.95
TestSelector_OrderByExprFunction · 0.45
TestWindowFunctionFunction · 0.45
OrderLenFunction · 0.45
OrderLenDescFunction · 0.45
OrderValueFunction · 0.45
OrderValueDescFunction · 0.45
TestWritePathFunction · 0.45
OrderByNeighborsCountFunction · 0.45
ModifierMethod · 0.45

Calls

no outgoing calls

Tested by 3

TestSelector_OrderByExprFunction · 0.36
TestWindowFunctionFunction · 0.36
TestWritePathFunction · 0.36