in reply to Code factory
Try DBIx::SQLEngine. It's a high level interface to SQL in the same vain as some of the suggestions you have gotten here. And its quite wonderful to use if it suits your program.
It works typically like this:
$sqldb->do_insert( table => 'students', values => { 'name'=>'Dave', 'age'=>'19', 'status'=>'minor' } ); $hashes = $sqldb->fetch_select( table => 'students', criteria => { 'status'=>'minor' } );
If your project is large and might be running for a while, you should wrap all the different calls to the database in separate functions even if you've got a nice generalized interface. You will eventually have to make some workarounds or sanity checking on the data before using them, and it's thankful to have that located one place.
Mats
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Code factory
by Notromda (Pilgrim) on Jul 08, 2003 at 14:13 UTC |