2 OCaml traits signature for sqlgg
6 This is free and unencumbered software released into the public domain.
8 Anyone is free to copy, modify, publish, use, compile, sell, or
9 distribute this software, either in source code form or as a compiled
10 binary, for any purpose, commercial or non-commercial, and by any
13 For more information, please refer to <http://unlicense.org/>
30 exception Oops
of string
32 val get_column_Bool
: row
-> int -> bool
33 val get_column_Int
: row
-> int -> num
34 val get_column_Text
: row
-> int -> text
35 val get_column_Any
: row
-> int -> any
36 val get_column_Float
: row
-> int -> float
37 val get_column_Datetime
: row
-> int -> datetime
39 val start_params
: statement
-> int -> params
40 val finish_params
: params
-> result
42 (** [set_param_* stmt index val]. [index] is 0-based,
43 @raise Oops on error *)
44 val set_param_null
: params
-> int -> unit
45 val set_param_Text
: params
-> int -> text
-> unit
46 val set_param_Any
: params
-> int -> any
-> unit
47 val set_param_Bool
: params
-> int -> bool -> unit
48 val set_param_Int
: params
-> int -> num
-> unit
49 val set_param_Float
: params
-> int -> float -> unit
50 val set_param_Datetime
: params
-> int -> datetime
-> unit
52 val no_params
: statement
-> result
55 Perform query and return results via callback for each row
58 val select
: connection
-> string -> (statement
-> result
) -> (row
-> unit) -> unit
61 Perform query and return first row if available
64 val select1
: connection
-> string -> (statement
-> result
) -> (row
-> 'b
) -> 'b
option
66 (** Execute non-query.
68 @return number of affected rows
70 val execute
: connection
-> string -> (statement
-> result
) -> int64