Though in a DAO situation there's little point in not selecting *
since the DAO generally is just going to get all the columns for a
specific record and drop them into the bean or other object
properties. You can of course argue that explicitly declaring the
columns is faster for the database (although you are using the primary
key for selection), and using a code-generator can shift that load
some, but I still prefer select * in a DAO because I also use dynamic
accessor methods and that way I don't have to rewrite my DAO's when I
add columns to the table. I tend to be very much of the "right tool
for the job" mindset, so if there's a practical reason for using a * I
have no problem with it.

> I guess we all have our admamant areas :) If I see a
> Select * I get
> fairly upset with the developer. In most caees you are
> bringing back
> unneeded data and in a large developement envirmoent
> another programer
> can not easily step into the code and see what is being
> selected from
> where.

> Adam H

> On 5/11/05, Glenn Saunders <[EMAIL PROTECTED]> wrote:
>> At 01:14 PM 5/9/2005, you wrote:
>> >That reminds me of one...Select * in SQL
>> >statements...thats a really
>> >big PITA and a sign of a beginner or a lazy coder...
>>
>> I guess that would make me a lazy coder.


s. isaac dealey   954.522.6080
new epoch : isn't it time for a change?

add features without fixtures with
the onTap open source framework

http://www.fusiontap.com
http://coldfusion.sys-con.com/author/4806Dealey.htm




~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:11:2624
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/11
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:11
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.11
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to