Simple DB Access

Serge Aleynikov <>
Sat Aug 5 02:53:39 CEST 2006


Christian S wrote:
> edbc:execute("SELECT * FROM foo WHERE id = $1", [Id])

One comment about a nice feature to have in edbc that I believe is 
specific to OCI - array DML inserts, where bind variables can contain an 
array of values.  This saves quite a bit on network round trips when 
inserting hundreds / thousands of records

edbc:execute_array(
     "insert into foo (field1, field2) values (:1, :2)",
     [ [ 1, 2, 3, 4 ], ["a","b","c","d"] ]
).

Serge



More information about the erlang-questions mailing list