source: project/wiki/dbi @ 8540

Last change on this file since 8540 was 8540, checked in by elf, 12 years ago

attempted fix for dbi

File size: 1.1 KB
Line 
1== DBI Discussion
2
3=== Streams
4
5How about using SRFI-40/41 streams as query results? This would allow us to use all of the stream-fold, stream-map, etc. functions.
6
7This may be a job for a library on top of DBI as well.
8
9=== Comparison of Current DB Intefaces
10
11<table>
12<tr>
13<th>Op</th>
14<th>MySQL</th>
15<th>PostgreSQL</th>
16<th>SQLite</th>
17</tr>
18<tr>
19<th>Connect</th>
20<td>mysql-connect</td>
21<td>pg:connect</td>
22<td>sqlite3:open</td>
23</tr>
24<tr>
25<th>Close</th>
26<td>mysql-close</td>
27<td>pg:close</td>
28<td>sqlite3:finalize!</td>
29</tr>
30<tr>
31<th>Query</th>
32<td>mysql-query</td>
33<td>&lt;none&gt;</td>
34<td>sqlite3:exec</td>
35</tr>
36<tr>
37<th>Fetch Row</th>
38<td>mysql-fetch-row</td>
39<td>&lt;none&gt;</td>
40<td>&lt;none&gt;</td>
41</tr>
42<tr>
43<th>Get Insert ID</th>
44<td>mysql-insert-id</td>
45<td>&lt;none&gt;</td>
46<td>sqlite3:last-insert-rowid</td>
47</tr>
48<tr>
49<th>Query for-each</th>
50<td>mysql-query-foreach</td>
51<td>pg:query-for-each</td>
52<td>sqlite3:for-each-row</td>
53</tr>
54<tr>
55<th>Query map</th>
56<td>&lt;none&gt;</td>
57<td>&lt;none&gt;</td>
58<td>sqlite3:map-row</td>
59</tr>
60<tr>
61<th>Query fold</th>
62<td>&lt;none&gt;</td>
63<td>pg:query-fold-left</td>
64<td>&lt;none&gt;</td>
65</tr>
66</table>
67
Note: See TracBrowser for help on using the repository browser.