Method

OmniPipelineSnapshotexecute_query_async

Declaration

void
omni_pipeline_snapshot_execute_query_async (
  OmniPipelineSnapshot* self,
  OmniPipelineQuery* query,
  GVariant* param_values,
  GCancellable* cancellable,
  GAsyncReadyCallback callback,
  void* user_data
)

Description

Execute a prepared query and get the result as a single record batch.

Query Parameters

param_values optionally specifies query parameters. If specified, it must take one of the following two forms:

  • param_values conforming to a{s*} specifies named parameters, i.e., each placeholder is replaced with the parameter value with the matching name. This form is not implemented yet.

  • param_values conforming to a* (but not a{s*}) specifies positional parameters, i.e., each placeholder is replaced wtih the parameter value with the matching position within the array.

It is not possible to mix both forms.

Parameter values are converted to an Arrow scalar value according to the following algorithm:

  1. If the provided variant is a boxed variant (v), execute this algorithm on the inner variant.

  2. If the provided variant represents a nothing value, return a null value.

  3. If the provided variant represents a just value, execute this algorithm on the inner variant.

  4. Convert the provided variant according to the following conversion table.

    Signature Arrow datatype
    b Boolean
    y UInt8
    n Int16
    q UInt16
    i Int32
    u UInt32
    x Int64
    t UInt64
    d Float64
    s Utf8
    ay Binary
  5. If the provided variant does not match any of the above types, raise an unsupported error.

Currently the resulting Arrow datatype must exactly match the expected one. Type coercion and nested types may be implemented in the future.

It is unspecified whether a nothing value of an unsupported type (e.g., `mh nothing`) causes an error.

Parameters

query

Type: OmniPipelineQuery

No description available.

The data is owned by the caller of the method.
param_values

Type: GVariant

No description available.

The argument can be NULL.
The data is owned by the caller of the method.
cancellable

Type: GCancellable

No description available.

The argument can be NULL.
The data is owned by the caller of the method.
callback

Type: GAsyncReadyCallback

No description available.

The argument can be NULL.
user_data

Type: void*

No description available.

The argument can be NULL.
The data is owned by the caller of the method.