in reply to Abstracting sql
Therefore I much prefer creating logical requests that map to perl subroutines (i.e. addNewUser(), getUserInformation(), etc) that either call SQL stored procedures (my preference) or, if these aren't available, have the SQL in the subroutine.
This will also have the advantage of forcing you to structure your app a little so that you only need to create a limited number of database access methods/subroutines. This will have a huge benefit on the maintainability of the database, and on figuring out what indexes are needed (f.ex. right now one of my clients has a largeish database (about 20GB) where there is very little structure - trying to figure out what indexes are needed, and what queries are actually run is a nightmare, requiring the use of "auditing" (i.e. recodring *all* SQL that is sent to the server) and sifting through gigabytes of SQL code...)
Michael
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Abstracting sql
by barbie (Deacon) on Jul 31, 2003 at 09:02 UTC | |
by princepawn (Parson) on Jul 31, 2003 at 17:14 UTC | |
|
Re: Re: Abstracting sql
by BUU (Prior) on Jul 31, 2003 at 13:46 UTC | |
by mpeppler (Vicar) on Jul 31, 2003 at 14:40 UTC | |
by BUU (Prior) on Jul 31, 2003 at 16:48 UTC |