`sig
type 'a t
type 'a monad
type isolation =
[ `Read_committed
| `Read_uncommitted
| `Repeatable_read
| `Serializable ]
type access = [ `Read_only | `Read_write ]
exception Error of string
exception PostgreSQL_Error of string * (char * string) list
val connect :
?host:string ->
?port:int ->
?user:string ->
?password:string ->
?database:string ->
?unix_domain_socket_dir:string ->
unit ->
'a PGOCaml_generic.PGOCAML_GENERIC.t
PGOCaml_generic.PGOCAML_GENERIC.monad
val close :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
unit PGOCaml_generic.PGOCAML_GENERIC.monad
val ping :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
unit PGOCaml_generic.PGOCAML_GENERIC.monad
val alive :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
bool PGOCaml_generic.PGOCAML_GENERIC.monad
val begin_work :
?isolation:PGOCaml_generic.PGOCAML_GENERIC.isolation ->
?access:PGOCaml_generic.PGOCAML_GENERIC.access ->
?deferrable:bool ->
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
unit PGOCaml_generic.PGOCAML_GENERIC.monad
val commit :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
unit PGOCaml_generic.PGOCAML_GENERIC.monad
val rollback :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
unit PGOCaml_generic.PGOCAML_GENERIC.monad
val transact :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?isolation:PGOCaml_generic.PGOCAML_GENERIC.isolation ->
?access:PGOCaml_generic.PGOCAML_GENERIC.access ->
?deferrable:bool ->
('a PGOCaml_generic.PGOCAML_GENERIC.t ->
'b PGOCaml_generic.PGOCAML_GENERIC.monad) ->
'b PGOCaml_generic.PGOCAML_GENERIC.monad
val serial :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
string -> int64 PGOCaml_generic.PGOCAML_GENERIC.monad
val serial4 :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
string -> int32 PGOCaml_generic.PGOCAML_GENERIC.monad
val serial8 :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
string -> int64 PGOCaml_generic.PGOCAML_GENERIC.monad
val max_message_length : int Pervasives.ref
val verbose : int Pervasives.ref
val set_private_data : 'a PGOCaml_generic.PGOCAML_GENERIC.t -> 'a -> unit
val private_data : 'a PGOCaml_generic.PGOCAML_GENERIC.t -> 'a
val uuid : 'a PGOCaml_generic.PGOCAML_GENERIC.t -> string
type pa_pg_data = (string, bool) Hashtbl.t
type oid = int32
type param = string option
type result = string option
type row = PGOCaml_generic.PGOCAML_GENERIC.result list
val prepare :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
query:string ->
?name:string ->
?types:PGOCaml_generic.PGOCAML_GENERIC.oid list ->
unit -> unit PGOCaml_generic.PGOCAML_GENERIC.monad
val execute_rev :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?name:string ->
?portal:string ->
params:PGOCaml_generic.PGOCAML_GENERIC.param list ->
unit ->
PGOCaml_generic.PGOCAML_GENERIC.row list
PGOCaml_generic.PGOCAML_GENERIC.monad
val execute :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?name:string ->
?portal:string ->
params:PGOCaml_generic.PGOCAML_GENERIC.param list ->
unit ->
PGOCaml_generic.PGOCAML_GENERIC.row list
PGOCaml_generic.PGOCAML_GENERIC.monad
val cursor :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?name:string ->
?portal:string ->
params:PGOCaml_generic.PGOCAML_GENERIC.param list ->
(PGOCaml_generic.PGOCAML_GENERIC.row ->
unit PGOCaml_generic.PGOCAML_GENERIC.monad) ->
unit PGOCaml_generic.PGOCAML_GENERIC.monad
val close_statement :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?name:string -> unit -> unit PGOCaml_generic.PGOCAML_GENERIC.monad
val close_portal :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?portal:string -> unit -> unit PGOCaml_generic.PGOCAML_GENERIC.monad
val inject :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?name:string ->
string ->
PGOCaml_generic.PGOCAML_GENERIC.row list
PGOCaml_generic.PGOCAML_GENERIC.monad
val alter :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?name:string -> string -> unit PGOCaml_generic.PGOCAML_GENERIC.monad
type row_description =
PGOCaml_generic.PGOCAML_GENERIC.result_description list
and result_description = {
name : string;
table : PGOCaml_generic.PGOCAML_GENERIC.oid option;
column : int option;
field_type : PGOCaml_generic.PGOCAML_GENERIC.oid;
length : int;
modifier : int32;
}
type params_description =
PGOCaml_generic.PGOCAML_GENERIC.param_description list
and param_description = {
param_type : PGOCaml_generic.PGOCAML_GENERIC.oid;
}
val describe_statement :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?name:string ->
unit ->
(PGOCaml_generic.PGOCAML_GENERIC.params_description *
PGOCaml_generic.PGOCAML_GENERIC.row_description option)
PGOCaml_generic.PGOCAML_GENERIC.monad
val describe_portal :
'a PGOCaml_generic.PGOCAML_GENERIC.t ->
?portal:string ->
unit ->
PGOCaml_generic.PGOCAML_GENERIC.row_description option
PGOCaml_generic.PGOCAML_GENERIC.monad
val name_of_type :
?modifier:int32 -> PGOCaml_generic.PGOCAML_GENERIC.oid -> string
type inet = Unix.inet_addr * int
type timestamptz = CalendarLib.Calendar.t * CalendarLib.Time_Zone.t
type int16 = int
type bytea = string
type point = float * float
type hstore = (string * string option) list
type numeric = string
type bool_array = bool option list
type int32_array = int32 option list
type int64_array = int64 option list
type string_array = string option list
type float_array = float option list
val string_of_oid : PGOCaml_generic.PGOCAML_GENERIC.oid -> string
val string_of_bool : bool -> string
val string_of_int : int -> string
val string_of_int16 : PGOCaml_generic.PGOCAML_GENERIC.int16 -> string
val string_of_int32 : int32 -> string
val string_of_int64 : int64 -> string
val string_of_float : float -> string
val string_of_point : PGOCaml_generic.PGOCAML_GENERIC.point -> string
val string_of_hstore : PGOCaml_generic.PGOCAML_GENERIC.hstore -> string
val string_of_numeric : PGOCaml_generic.PGOCAML_GENERIC.numeric -> string
val string_of_inet : PGOCaml_generic.PGOCAML_GENERIC.inet -> string
val string_of_timestamp : CalendarLib.Calendar.t -> string
val string_of_timestamptz :
PGOCaml_generic.PGOCAML_GENERIC.timestamptz -> string
val string_of_date : CalendarLib.Date.t -> string
val string_of_time : CalendarLib.Time.t -> string
val string_of_interval : CalendarLib.Calendar.Period.t -> string
val string_of_bytea : PGOCaml_generic.PGOCAML_GENERIC.bytea -> string
val string_of_string : string -> string
val string_of_unit : unit -> string
val string_of_bool_array :
PGOCaml_generic.PGOCAML_GENERIC.bool_array -> string
val string_of_int32_array :
PGOCaml_generic.PGOCAML_GENERIC.int32_array -> string
val string_of_int64_array :
PGOCaml_generic.PGOCAML_GENERIC.int64_array -> string
val string_of_string_array :
PGOCaml_generic.PGOCAML_GENERIC.string_array -> string
val string_of_float_array :
PGOCaml_generic.PGOCAML_GENERIC.float_array -> string
val oid_of_string : string -> PGOCaml_generic.PGOCAML_GENERIC.oid
val bool_of_string : string -> bool
val int_of_string : string -> int
val int16_of_string : string -> PGOCaml_generic.PGOCAML_GENERIC.int16
val int32_of_string : string -> int32
val int64_of_string : string -> int64
val float_of_string : string -> float
val point_of_string : string -> PGOCaml_generic.PGOCAML_GENERIC.point
val hstore_of_string : string -> PGOCaml_generic.PGOCAML_GENERIC.hstore
val numeric_of_string : string -> PGOCaml_generic.PGOCAML_GENERIC.numeric
val inet_of_string : string -> PGOCaml_generic.PGOCAML_GENERIC.inet
val timestamp_of_string : string -> CalendarLib.Calendar.t
val timestamptz_of_string :
string -> PGOCaml_generic.PGOCAML_GENERIC.timestamptz
val date_of_string : string -> CalendarLib.Date.t
val time_of_string : string -> CalendarLib.Time.t
val interval_of_string : string -> CalendarLib.Calendar.Period.t
val bytea_of_string : string -> PGOCaml_generic.PGOCAML_GENERIC.bytea
val unit_of_string : string -> unit
val bool_array_of_string :
string -> PGOCaml_generic.PGOCAML_GENERIC.bool_array
val int32_array_of_string :
string -> PGOCaml_generic.PGOCAML_GENERIC.int32_array
val int64_array_of_string :
string -> PGOCaml_generic.PGOCAML_GENERIC.int64_array
val string_array_of_string :
string -> PGOCaml_generic.PGOCAML_GENERIC.string_array
val float_array_of_string :
string -> PGOCaml_generic.PGOCAML_GENERIC.float_array
val bind :
'a PGOCaml_generic.PGOCAML_GENERIC.monad ->
('a -> 'b PGOCaml_generic.PGOCAML_GENERIC.monad) ->
'b PGOCaml_generic.PGOCAML_GENERIC.monad
val return : 'a -> 'a PGOCaml_generic.PGOCAML_GENERIC.monad
end`