65.9K
CodeProject is changing. Read more.
Home

The Evil That is "Select *"

starIconstarIconstarIconstarIconstarIcon

5.00/5 (2 votes)

Aug 2, 2011

CPOL
viewsIcon

7279

I agree with this. However, typing all of the columns can be tedious! Now imagine you are working with a table with DOZENS of columns?! SELECT * FROM DENORMALIZEDTABLE1If you are using MS-SQL or writing a query in MS Visual Studio then there is a trick. You can: * write the select *...

I agree with this. However, typing all of the columns can be tedious! Now imagine you are working with a table with DOZENS of columns?!
SELECT * FROM DENORMALIZEDTABLE1
If you are using MS-SQL or writing a query in MS Visual Studio then there is a trick. You can: * write the select * like above * hilight the query * right click * and select "Design query in editor.." * Click Ok to close the query editor Poof! The SELECT * has been replaced with explicit column names! No excuses!