package caqti-driver-mariadb

  1. Overview
  2. Docs
On This Page
  1. Error Details
Legend:
Library
Module
Module type
Parameter
Class
Class type

Caqti driver for MariaDB (bindings).

This driver is implemented in terms of the mariadb OPAM package. It handles URIs of the form mariadb://<user>:<password>@<host>:<port>/?<query> with the following query arguments:

  • socket=<socket> requests a UNIX domain socket connection
  • config-group=<name> loads additional settings from the section <name> of the default configuration file. Default: "caqti".

Except for the latter, options are passed to the correspondingly named arguments to the connect function of MariaDB. All parts of the URL are optional, except that the chosen combination must suffice to establish a connection.

The interface provided by this module should normally not be used by applications, but provides access to some MariaDB specifics in case they are needed.

Error Details

The following provides access to diagnostics collected from the MariaDB connection and statement objects.

type Caqti_error.msg +=
  1. | Error_msg of {
    1. errno : int;
      (*

      The error number returned by mysql_errno or mysql_stmt_errno.

      *)
    2. error : string;
      (*

      The error message returned by mysql_error or mysql_stmt_errno.

      *)
    }
OCaml

Innovation. Community. Security.