<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <link rel="stylesheet" href="style.css" type="text/css"> <meta content="text/html; charset=iso-8859-1" http-equiv="Content-Type"> <link rel="Start" href="index.html"> <link rel="previous" href="PGOCaml_generic.THREAD.html"> <link rel="Up" href="PGOCaml_generic.html"> <link title="Index of types" rel=Appendix href="index_types.html"> <link title="Index of exceptions" rel=Appendix href="index_exceptions.html"> <link title="Index of values" rel=Appendix href="index_values.html"> <link title="Index of modules" rel=Appendix href="index_modules.html"> <link title="Index of module types" rel=Appendix href="index_module_types.html"> <link title="PGOCaml" rel="Chapter" href="PGOCaml.html"> <link title="PGOCaml_generic" rel="Chapter" href="PGOCaml_generic.html"><link title="Connection management" rel="Section" href="#6_Connectionmanagement"> <link title="Transactions" rel="Section" href="#6_Transactions"> <link title="Serial column" rel="Section" href="#6_Serialcolumn"> <link title="Miscellaneous" rel="Section" href="#6_Miscellaneous"> <link title="Low level query interface - DO NOT USE DIRECTLY" rel="Section" href="#6_LowlevelqueryinterfaceDONOTUSEDIRECTLY"> <link title="Low level type conversion functions - DO NOT USE DIRECTLY" rel="Section" href="#6_LowleveltypeconversionfunctionsDONOTUSEDIRECTLY"> <title>PGOCaml_generic.PGOCAML_GENERIC</title> </head> <body> <div class="navbar"><a href="PGOCaml_generic.THREAD.html">Previous</a> <a href="PGOCaml_generic.html">Up</a> </div> <center><h1>Module type <a href="type_PGOCaml_generic.PGOCAML_GENERIC.html">PGOCaml_generic.PGOCAML_GENERIC</a></h1></center> <br> <pre><span class="keyword">module type</span> PGOCAML_GENERIC = <code class="code">sig</code> <a href="PGOCaml_generic.PGOCAML_GENERIC.html">..</a> <code class="code">end</code></pre><hr width="100%"> <pre><span id="TYPEt"><span class="keyword">type</span> <code class="type">'a</code> t</span> </pre> <div class="info"> Database handle.<br> </div> <pre><span id="TYPEmonad"><span class="keyword">type</span> <code class="type">'a</code> monad</span> </pre> <pre><span id="EXCEPTIONError"><span class="keyword">exception</span> Error</span> <span class="keyword">of</span> <code class="type">string</code></pre> <div class="info"> For library errors.<br> </div> <pre><span id="EXCEPTIONPostgreSQL_Error"><span class="keyword">exception</span> PostgreSQL_Error</span> <span class="keyword">of</span> <code class="type">string * (char * string) list</code></pre> <div class="info"> For errors generated by the PostgreSQL database back-end. The first argument is a printable error message. The second argument is the complete set of error fields returned from the back-end. See <code class="code">http://www.postgresql.org/docs/8.1/static/protocol-error-fields.html</code><br> </div> <br> <span id="6_Connectionmanagement"><h6>Connection management</h6></span><br> <pre><span id="VALconnect"><span class="keyword">val</span> connect</span> : <code class="type">?host:string -><br> ?port:int -><br> ?user:string -><br> ?password:string -><br> ?database:string -><br> ?unix_domain_socket_dir:string -><br> unit -><br> 'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> Connect to the database. The normal <code class="code">$PGDATABASE</code>, etc. environment variables are available.<br> </div> <pre><span id="VALclose"><span class="keyword">val</span> close</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> unit <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> Close the database handle. You must call this after you have finished with the handle, or else you will get leaked file descriptors.<br> </div> <pre><span id="VALping"><span class="keyword">val</span> ping</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> unit <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> Ping the database. If the database is not available, some sort of exception will be thrown.<br> </div> <br> <span id="6_Transactions"><h6>Transactions</h6></span><br> <pre><span id="VALbegin_work"><span class="keyword">val</span> begin_work</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> unit <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> Start a transaction.<br> </div> <pre><span id="VALcommit"><span class="keyword">val</span> commit</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> unit <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> Perform a COMMIT operation on the database.<br> </div> <pre><span id="VALrollback"><span class="keyword">val</span> rollback</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> unit <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> Perform a ROLLBACK operation on the database.<br> </div> <br> <span id="6_Serialcolumn"><h6>Serial column</h6></span><br> <pre><span id="VALserial"><span class="keyword">val</span> serial</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> string -> int64 <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> This is a shorthand for <code class="code">SELECT CURRVAL(serial)</code>. For a table called <code class="code">table</code> with serial column <code class="code">id</code> you would typically call this as <code class="code">serial dbh "table_id_seq"</code> after the previous INSERT operation to get the serial number of the inserted row.<br> </div> <pre><span id="VALserial4"><span class="keyword">val</span> serial4</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> string -> int32 <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> As <code class="code">PGOCaml.serial</code> but assumes that the column is a SERIAL or SERIAL4 type.<br> </div> <pre><span id="VALserial8"><span class="keyword">val</span> serial8</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> string -> int64 <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> Same as <code class="code">PGOCaml.serial</code>.<br> </div> <br> <span id="6_Miscellaneous"><h6>Miscellaneous</h6></span><br> <pre><span id="VALmax_message_length"><span class="keyword">val</span> max_message_length</span> : <code class="type">int Pervasives.ref</code></pre><div class="info"> Maximum message length accepted from the back-end. The default is <code class="code">Sys.max_string_length</code>, which means that we will try to read as much data from the back-end as we can, and this may cause us to run out of memory (particularly on 64 bit machines), causing a possible denial of service. You may want to set this to a smaller size to avoid this happening.<br> </div> <pre><span id="VALverbose"><span class="keyword">val</span> verbose</span> : <code class="type">int Pervasives.ref</code></pre><div class="info"> Verbosity. 0 means don't print anything. 1 means print short error messages as returned from the back-end. 2 means print all messages as returned from the back-end. Messages are printed on <code class="code">stderr</code>. Default verbosity level is 1.<br> </div> <pre><span id="VALset_private_data"><span class="keyword">val</span> set_private_data</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -> 'a -> unit</code></pre><div class="info"> Attach some private data to the database handle. <p> NB. The pa_pgsql camlp4 extension uses this for its own purposes, which means that in most programs you will not be able to attach private data to the database handle.<br> </div> <pre><span id="VALprivate_data"><span class="keyword">val</span> private_data</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -> 'a</code></pre><div class="info"> Retrieve some private data previously attached to the database handle. If no data has been attached, raises <code class="code">Not_found</code>. <p> NB. The pa_pgsql camlp4 extension uses this for its own purposes, which means that in most programs you will not be able to attach private data to the database handle.<br> </div> <pre><span id="TYPEpa_pg_data"><span class="keyword">type</span> <code class="type"></code>pa_pg_data</span> = <code class="type">(string, bool) Hashtbl.t</code> </pre> <div class="info"> When using pa_pgsql, database handles have type <code class="code">PGOCaml.pa_pg_data PGOCaml.t</code><br> </div> <br> <span id="6_LowlevelqueryinterfaceDONOTUSEDIRECTLY"><h6>Low level query interface - DO NOT USE DIRECTLY</h6></span><br> <pre><span id="TYPEoid"><span class="keyword">type</span> <code class="type"></code>oid</span> = <code class="type">int32</code> </pre> <pre><span id="TYPEparam"><span class="keyword">type</span> <code class="type"></code>param</span> = <code class="type">string option</code> </pre> <div class="info"> None is NULL.<br> </div> <pre><span id="TYPEresult"><span class="keyword">type</span> <code class="type"></code>result</span> = <code class="type">string option</code> </pre> <div class="info"> None is NULL.<br> </div> <pre><span id="TYPErow"><span class="keyword">type</span> <code class="type"></code>row</span> = <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEresult">result</a> list</code> </pre> <div class="info"> One row is a list of fields.<br> </div> <pre><span id="VALprepare"><span class="keyword">val</span> prepare</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> query:string -><br> ?name:string -><br> ?types:<a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEoid">oid</a> list -><br> unit -> unit <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> <code class="code">prepare conn ~query ?name ?types ()</code> prepares the statement <code class="code">query</code> and optionally names it <code class="code">name</code> and sets the parameter types to <code class="code">types</code>. If no name is given, then the "unnamed" statement is overwritten. If no types are given, then the PostgreSQL engine infers types. Synchronously checks for errors.<br> </div> <pre><span id="VALexecute_rev"><span class="keyword">val</span> execute_rev</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> ?name:string -><br> ?portal:string -><br> params:<a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEparam">param</a> list -><br> unit -><br> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPErow">row</a> list<br> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><pre><span id="VALexecute"><span class="keyword">val</span> execute</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> ?name:string -><br> ?portal:string -><br> params:<a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEparam">param</a> list -><br> unit -><br> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPErow">row</a> list<br> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> <code class="code">execute conn ?name ~params ()</code> executes the named or unnamed statement <code class="code">name</code>, with the given parameters <code class="code">params</code>, returning the result rows (if any). <p> There are several steps involved at the protocol layer: (1) a "portal" is created from the statement, binding the parameters in the statement (Bind). (2) the portal is executed (Execute). (3) we synchronise the connection (Sync). <p> The optional <code class="code">?portal</code> parameter may be used to name the portal created in step (1) above (otherwise the unnamed portal is used). This is only important if you want to call <code class="code">PGOCaml.describe_portal</code> to find out the result types.<br> </div> <pre><span id="VALclose_statement"><span class="keyword">val</span> close_statement</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> ?name:string -> unit -> unit <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> <code class="code">close_statement conn ?name ()</code> closes a prepared statement and frees up any resources.<br> </div> <pre><span id="VALclose_portal"><span class="keyword">val</span> close_portal</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> ?portal:string -> unit -> unit <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> <code class="code">close_portal conn ?portal ()</code> closes a portal and frees up any resources.<br> </div> <pre><span id="TYPErow_description"><span class="keyword">type</span> <code class="type"></code>row_description</span> = <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEresult_description">result_description</a> list</code> </pre> <br><code><span id="TYPEresult_description"><span class="keyword">type</span> <code class="type"></code>result_description</span> = {</code><table class="typetable"> <tr> <td align="left" valign="top" > <code> </code></td> <td align="left" valign="top" > <code>name : <code class="type">string</code>;</code></td> <td class="typefieldcomment" align="left" valign="top" ><code>(*</code></td><td class="typefieldcomment" align="left" valign="top" >Field name.</td><td class="typefieldcomment" align="left" valign="bottom" ><code>*)</code></td> </tr> <tr> <td align="left" valign="top" > <code> </code></td> <td align="left" valign="top" > <code>table : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEoid">oid</a> option</code>;</code></td> <td class="typefieldcomment" align="left" valign="top" ><code>(*</code></td><td class="typefieldcomment" align="left" valign="top" >OID of table.</td><td class="typefieldcomment" align="left" valign="bottom" ><code>*)</code></td> </tr> <tr> <td align="left" valign="top" > <code> </code></td> <td align="left" valign="top" > <code>column : <code class="type">int option</code>;</code></td> <td class="typefieldcomment" align="left" valign="top" ><code>(*</code></td><td class="typefieldcomment" align="left" valign="top" >Column number of field in table.</td><td class="typefieldcomment" align="left" valign="bottom" ><code>*)</code></td> </tr> <tr> <td align="left" valign="top" > <code> </code></td> <td align="left" valign="top" > <code>field_type : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEoid">oid</a></code>;</code></td> <td class="typefieldcomment" align="left" valign="top" ><code>(*</code></td><td class="typefieldcomment" align="left" valign="top" >The type of the field.</td><td class="typefieldcomment" align="left" valign="bottom" ><code>*)</code></td> </tr> <tr> <td align="left" valign="top" > <code> </code></td> <td align="left" valign="top" > <code>length : <code class="type">int</code>;</code></td> <td class="typefieldcomment" align="left" valign="top" ><code>(*</code></td><td class="typefieldcomment" align="left" valign="top" >Length of the field.</td><td class="typefieldcomment" align="left" valign="bottom" ><code>*)</code></td> </tr> <tr> <td align="left" valign="top" > <code> </code></td> <td align="left" valign="top" > <code>modifier : <code class="type">int32</code>;</code></td> <td class="typefieldcomment" align="left" valign="top" ><code>(*</code></td><td class="typefieldcomment" align="left" valign="top" >Type modifier.</td><td class="typefieldcomment" align="left" valign="bottom" ><code>*)</code></td> </tr></table> } <pre><span id="TYPEparams_description"><span class="keyword">type</span> <code class="type"></code>params_description</span> = <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEparam_description">param_description</a> list</code> </pre> <br><code><span id="TYPEparam_description"><span class="keyword">type</span> <code class="type"></code>param_description</span> = {</code><table class="typetable"> <tr> <td align="left" valign="top" > <code> </code></td> <td align="left" valign="top" > <code>param_type : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEoid">oid</a></code>;</code></td> <td class="typefieldcomment" align="left" valign="top" ><code>(*</code></td><td class="typefieldcomment" align="left" valign="top" >The type of the parameter.</td><td class="typefieldcomment" align="left" valign="bottom" ><code>*)</code></td> </tr></table> } <pre><span id="VALdescribe_statement"><span class="keyword">val</span> describe_statement</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> ?name:string -><br> unit -><br> (<a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEparams_description">params_description</a> *<br> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPErow_description">row_description</a> option)<br> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> <code class="code">describe_statement conn ?name ()</code> describes the named or unnamed statement's parameter types and result types.<br> </div> <pre><span id="VALdescribe_portal"><span class="keyword">val</span> describe_portal</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEt">t</a> -><br> ?portal:string -><br> unit -><br> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPErow_description">row_description</a> option<br> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><div class="info"> <code class="code">describe_portal conn ?portal ()</code> describes the named or unnamed portal's result types.<br> </div> <br> <span id="6_LowleveltypeconversionfunctionsDONOTUSEDIRECTLY"><h6>Low level type conversion functions - DO NOT USE DIRECTLY</h6></span><br> <pre><span id="VALname_of_type"><span class="keyword">val</span> name_of_type</span> : <code class="type">?modifier:int32 -> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEoid">oid</a> -> string</code></pre><div class="info"> Returns the OCaml equivalent type name to the PostgreSQL type <code class="code">oid</code>. For instance, <code class="code">name_of_type (Int32.of_int 23)</code> returns <code class="code">"int32"</code> because the OID for PostgreSQL's internal <code class="code">int4</code> type is <code class="code">23</code>. As another example, <code class="code">name_of_type (Int32.of_int 25)</code> returns <code class="code">"string"</code>.<br> </div> <pre><span id="TYPEinet"><span class="keyword">type</span> <code class="type"></code>inet</span> = <code class="type">Unix.inet_addr * int</code> </pre> <pre><span id="TYPEtimestamptz"><span class="keyword">type</span> <code class="type"></code>timestamptz</span> = <code class="type">CalendarLib.Calendar.t * CalendarLib.Time_Zone.t</code> </pre> <pre><span id="TYPEint16"><span class="keyword">type</span> <code class="type"></code>int16</span> = <code class="type">int</code> </pre> <pre><span id="TYPEbytea"><span class="keyword">type</span> <code class="type"></code>bytea</span> = <code class="type">string</code> </pre> <pre><span id="TYPEpoint"><span class="keyword">type</span> <code class="type"></code>point</span> = <code class="type">float * float</code> </pre> <pre><span id="TYPEint32_array"><span class="keyword">type</span> <code class="type"></code>int32_array</span> = <code class="type">int32 array</code> </pre> <pre><span id="VALstring_of_oid"><span class="keyword">val</span> string_of_oid</span> : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEoid">oid</a> -> string</code></pre><pre><span id="VALstring_of_bool"><span class="keyword">val</span> string_of_bool</span> : <code class="type">bool -> string</code></pre><pre><span id="VALstring_of_int"><span class="keyword">val</span> string_of_int</span> : <code class="type">int -> string</code></pre><pre><span id="VALstring_of_int16"><span class="keyword">val</span> string_of_int16</span> : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEint16">int16</a> -> string</code></pre><pre><span id="VALstring_of_int32"><span class="keyword">val</span> string_of_int32</span> : <code class="type">int32 -> string</code></pre><pre><span id="VALstring_of_int64"><span class="keyword">val</span> string_of_int64</span> : <code class="type">int64 -> string</code></pre><pre><span id="VALstring_of_float"><span class="keyword">val</span> string_of_float</span> : <code class="type">float -> string</code></pre><pre><span id="VALstring_of_point"><span class="keyword">val</span> string_of_point</span> : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEpoint">point</a> -> string</code></pre><pre><span id="VALstring_of_inet"><span class="keyword">val</span> string_of_inet</span> : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEinet">inet</a> -> string</code></pre><pre><span id="VALstring_of_timestamp"><span class="keyword">val</span> string_of_timestamp</span> : <code class="type">CalendarLib.Calendar.t -> string</code></pre><pre><span id="VALstring_of_timestamptz"><span class="keyword">val</span> string_of_timestamptz</span> : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEtimestamptz">timestamptz</a> -> string</code></pre><pre><span id="VALstring_of_date"><span class="keyword">val</span> string_of_date</span> : <code class="type">CalendarLib.Date.t -> string</code></pre><pre><span id="VALstring_of_time"><span class="keyword">val</span> string_of_time</span> : <code class="type">CalendarLib.Time.t -> string</code></pre><pre><span id="VALstring_of_interval"><span class="keyword">val</span> string_of_interval</span> : <code class="type">CalendarLib.Calendar.Period.t -> string</code></pre><pre><span id="VALstring_of_int32_array"><span class="keyword">val</span> string_of_int32_array</span> : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEint32_array">int32_array</a> -> string</code></pre><pre><span id="VALstring_of_bytea"><span class="keyword">val</span> string_of_bytea</span> : <code class="type"><a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEbytea">bytea</a> -> string</code></pre><pre><span id="VALstring_of_string"><span class="keyword">val</span> string_of_string</span> : <code class="type">string -> string</code></pre><pre><span id="VALstring_of_unit"><span class="keyword">val</span> string_of_unit</span> : <code class="type">unit -> string</code></pre><pre><span id="VALoid_of_string"><span class="keyword">val</span> oid_of_string</span> : <code class="type">string -> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEoid">oid</a></code></pre><pre><span id="VALbool_of_string"><span class="keyword">val</span> bool_of_string</span> : <code class="type">string -> bool</code></pre><pre><span id="VALint_of_string"><span class="keyword">val</span> int_of_string</span> : <code class="type">string -> int</code></pre><pre><span id="VALint16_of_string"><span class="keyword">val</span> int16_of_string</span> : <code class="type">string -> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEint16">int16</a></code></pre><pre><span id="VALint32_of_string"><span class="keyword">val</span> int32_of_string</span> : <code class="type">string -> int32</code></pre><pre><span id="VALint64_of_string"><span class="keyword">val</span> int64_of_string</span> : <code class="type">string -> int64</code></pre><pre><span id="VALfloat_of_string"><span class="keyword">val</span> float_of_string</span> : <code class="type">string -> float</code></pre><pre><span id="VALpoint_of_string"><span class="keyword">val</span> point_of_string</span> : <code class="type">string -> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEpoint">point</a></code></pre><pre><span id="VALinet_of_string"><span class="keyword">val</span> inet_of_string</span> : <code class="type">string -> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEinet">inet</a></code></pre><pre><span id="VALtimestamp_of_string"><span class="keyword">val</span> timestamp_of_string</span> : <code class="type">string -> CalendarLib.Calendar.t</code></pre><pre><span id="VALtimestamptz_of_string"><span class="keyword">val</span> timestamptz_of_string</span> : <code class="type">string -> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEtimestamptz">timestamptz</a></code></pre><pre><span id="VALdate_of_string"><span class="keyword">val</span> date_of_string</span> : <code class="type">string -> CalendarLib.Date.t</code></pre><pre><span id="VALtime_of_string"><span class="keyword">val</span> time_of_string</span> : <code class="type">string -> CalendarLib.Time.t</code></pre><pre><span id="VALinterval_of_string"><span class="keyword">val</span> interval_of_string</span> : <code class="type">string -> CalendarLib.Calendar.Period.t</code></pre><pre><span id="VALint32_array_of_string"><span class="keyword">val</span> int32_array_of_string</span> : <code class="type">string -> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEint32_array">int32_array</a></code></pre><pre><span id="VALbytea_of_string"><span class="keyword">val</span> bytea_of_string</span> : <code class="type">string -> <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEbytea">bytea</a></code></pre><pre><span id="VALunit_of_string"><span class="keyword">val</span> unit_of_string</span> : <code class="type">string -> unit</code></pre><div class="info"> These conversion functions are used by pa_pgsql to convert values in and out of the database.<br> </div> <pre><span id="VALbind"><span class="keyword">val</span> bind</span> : <code class="type">'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a> -><br> ('a -> 'b <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a>) -><br> 'b <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre><pre><span id="VALreturn"><span class="keyword">val</span> return</span> : <code class="type">'a -> 'a <a href="PGOCaml_generic.PGOCAML_GENERIC.html#TYPEmonad">monad</a></code></pre></body></html>