… | |
… | |
44 | use DBI (); |
44 | use DBI (); |
45 | |
45 | |
46 | BEGIN { |
46 | BEGIN { |
47 | use base qw(Exporter DynaLoader); |
47 | use base qw(Exporter DynaLoader); |
48 | |
48 | |
49 | $VERSION = 0.131; |
49 | $VERSION = 0.141; |
50 | @EXPORT = qw( |
50 | @EXPORT = qw( |
51 | sql_exec sql_fetch sql_fetchall sql_exists sql_insertid $sql_exec |
51 | sql_exec sql_fetch sql_fetchall sql_exists sql_insertid $sql_exec |
52 | sql_uexec sql_ufetch sql_ufetchall sql_uexists |
52 | sql_uexec sql_ufetch sql_ufetchall sql_uexists |
53 | ); |
53 | ); |
54 | @EXPORT_OK = qw( |
54 | @EXPORT_OK = qw( |
… | |
… | |
318 | |
318 | |
319 | =item [old-size] = cachesize [new-size] |
319 | =item [old-size] = cachesize [new-size] |
320 | |
320 | |
321 | Returns (and possibly changes) the LRU cache size used by C<sql_exec>. The |
321 | Returns (and possibly changes) the LRU cache size used by C<sql_exec>. The |
322 | default is somewhere around 50 (= the 50 last recently used statements |
322 | default is somewhere around 50 (= the 50 last recently used statements |
323 | will be cached). It shouldn't be too large, since a simple linear listed |
323 | will be cached). It shouldn't be too large, since a simple linear list |
324 | is used for the cache at the moment (which, for small (<100) cache sizes |
324 | is used for the cache at the moment (which, for small (<100) cache sizes |
325 | is actually quite fast). |
325 | is actually quite fast). |
326 | |
326 | |
327 | The function always returns the cache size in effect I<before> the call, |
327 | The function always returns the cache size in effect I<before> the call, |
328 | so, to nuke the cache (for example, when a database connection has died |
328 | so, to nuke the cache (for example, when a database connection has died |