The problem is that now any code that needs to use the database object is loading a lot of code that it doesn't need.
And this is a problem why?
(serious question - this is smelling a little like premature optimisation to me :-)
is it considered "better" to have each object (User object, Item object) carry it's own SQL code?
In general no. I would always try an isolate the SQL code into a separate module or the database itself.
In reply to Re: Separation of SQL code
by adrianh
in thread (z) Separation of SQL code
by zigdon
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |