package caqti

  1. Overview
  2. Docs
Abstraction over multiple database libraries

Install

Dune Dependency

Authors

Maintainers

Sources

caqti-0.9.0.tbz
sha256=4c84a16d983d0fed2786f536a3fa4d8fa113b8b30b4deea4a74772582d5489b2
md5=42a2e2d3b73d7fbaecc618549aad2865

doc/caqti.v1/Caqti1_describe/index.html

Module Caqti1_describeSource

(v1) Types and utility functions for query descriptions.

  • deprecated

    Don't use this in new code.

Sourcetype typedesc = [
  1. | `Bool
  2. | `Int
  3. | `Float
  4. | `String
  5. | `Bytes
  6. | `Date
  7. | `Utc
  8. | `Other of string
  9. | `Unknown
]

Identification of a remote type. These correspond to the types described in Caqti_sigs.CONNECTION.Param. `Other s represents an backend-specific type s. The additional `Unknown tag is used by backends which are unable to determine parameter types.

Sourcetype querydesc = {
  1. querydesc_params : typedesc array;
    (*

    The types of the expected parameters for a query. The number of parameters should always correspond to the length of the array, but the parameters may be `Unknown in case the backend is unable to determine them.

    *)
  2. querydesc_fields : (string * typedesc) array;
    (*

    The names and types of components of tuples returned by the query.

    *)
}

The result of Caqti_sigs.CONNECTION.describe.

Sourceval string_of_typedesc : typedesc -> string

An informative textual representation of a type.

Sourceval string_of_querydesc : querydesc -> string

An informative textual description of query parameters and results.

OCaml

Innovation. Community. Security.