Interface CallFunction<T>
- Type Parameters:
T- The function's return type.
- All Superinterfaces:
Attachable, AttachableQueryPart, Fields, Flow.Publisher<Record1<T>>, Iterable<Record1<T>>, Publisher<Record1<T>>, org.reactivestreams.Publisher<Record1<T>>, Query, QueryPart, ResultQuery<Record1<T>>, Serializable, Statement
- All Known Subinterfaces:
QOM.CallFunction<T>
A call to a stored scalar function, created from
CallReturnsStep.returns(DataType).
The call can be used in different ways:
- As a
ResultQuery: The function call is executed in aSELECTstatement, e.g.SELECT f(?, ?). - As a
Field:asField()produces the plain function callf(?, ?), which can be used in other queries wherever aFieldcan be used.
Example:
// Executing the function call
Integer i = ctx.fetchValue(call(name("f")).args(val(1)).returns(INTEGER));
// Embedding the function call in another query
Field<Integer> f = call(name("f")).args(BOOK.ID).returns(INTEGER).asField();
Result<Record2<Integer, Integer>> result =
ctx.select(BOOK.ID, f)
.from(BOOK)
.fetch();
- Author:
- Lukas Eder
-
Method Summary
Methods inherited from interface Attachable
attach, configuration, detachMethods inherited from interface AttachableQueryPart
getBindValues, getParam, getParams, getSQL, getSQLMethods inherited from interface Fields
dataType, dataType, dataType, dataTypes, field, field, field, field, field, field, field, field, field, field, fields, fields, fields, fields, fields, fieldsIncludingHidden, fieldsRow, fieldStream, indexOf, indexOf, indexOf, type, type, type, typesMethods inherited from interface org.reactivestreams.Publisher
subscribeMethods inherited from interface Query
cancel, execute, executeAsync, executeAsync, executeLarge, executeLargeAsync, executeLargeAsync, isExecutableMethods inherited from interface QueryPart
$replace, $replace, $traverse, $traverse, equals, hashCode, toStringMethods inherited from interface ResultQuery
bind, bind, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, coerce, collect, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetch, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAny, fetchAnyArray, fetchAnyInto, fetchAnyInto, fetchAnyMap, fetchArray, fetchArray, fetchArray, fetchArray, fetchArray, fetchArray, fetchArray, fetchArray, fetchArray, fetchArray, fetchArray, fetchArray, fetchArray, fetchArrays, fetchAsync, fetchAsync, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchGroups, fetchInto, fetchInto, fetchInto, fetchLazy, fetchMany, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMap, fetchMaps, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOne, fetchOneArray, fetchOneInto, fetchOneInto, fetchOneMap, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptional, fetchOptionalArray, fetchOptionalInto, fetchOptionalInto, fetchOptionalMap, fetchResultSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSet, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingle, fetchSingleArray, fetchSingleInto, fetchSingleInto, fetchSingleMap, fetchSize, fetchStream, fetchStreamInto, fetchStreamInto, forEach, getRecordType, getResult, iterator, keepStatement, largeMaxRows, maxRows, poolable, queryTimeout, resultSetConcurrency, resultSetHoldability, resultSetType, spliterator, stream
-
Method Details
-
asField
-
asField
-