that's one reason
another is that it's easier to delete the last one
with the comma at the back, you have to delete a line PLUS go to the end of the previous line to edit that
i dunno about you, but i'm not moving my mouse when i text edit, and it's easier to just delete a line using shift-downarrow and the delete key and then you're done
but the most compelling argument is that you can easily see where the actual columns are if they are expressions
for example, and do this honestly withou looking ahead, how many columns does this query produce --
Code:
select id ,
Description ,
length(Description) as len ,
length(replace(Description,'games','')) as lrep,
( length(Description) -
length(replace(Description,'games','')) ) /
length('games') as occ ,
length(Description) + 1 -
length(replace(Description,' ','')) as wds,
(( length(Description) -
length(replace(Description,'games','')) ) /
length('games') ) /
(length(Description) + 1 -
length(replace(Description,' ','')) ) as occwds,
( length(Description) -
length(replace(Description,'games','')) ) /
length(Description) as occlen
from keyword_relevance
where Description like '%games%'
give up?
okay, now how many --> Simple Keyword Relevance
later this spring, joe celko has a new book coming out called SQL Programming Style which you may find interesting
Bookmarks