August 1, 2008 at 11:32 am
Stumbled across this at work, just had to share.
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_NULLS ON
GO
ALTER procedure dbo.spProviderDirectoryReportWithAllServiceLocations
AS
Select *
From
vwProviderDirectoryReportWithAllServiceLocations
GO
SET QUOTED_IDENTIFIER OFF
GO
SET ANSI_NULLS ON
GO
How's that for efficient? :w00t:
---------------------------------------------------------
How best to post your question[/url]
How to post performance problems[/url]
Tally Table:What it is and how it replaces a loop[/url]
"stewsterl 80804 (10/16/2009)I guess when you stop and try to understand the solution provided you not only learn, but save yourself some headaches when you need to make any slight changes."
August 1, 2008 at 12:25 pm
Sweet. Nice security. No one will ever know that we're running everything off an Access DB
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 1, 2008 at 12:33 pm
Very nice.
August 1, 2008 at 3:30 pm
That guy needs a raise! 😛
August 1, 2008 at 3:39 pm
I can't help but wonder if the view definition looks something like:
create view vwProviderDirectoryReportWithAllServiceLocations
as
Select *
From
ProviderDirectoryReportWithAllServiceLocations
end
For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]
August 1, 2008 at 8:14 pm
Heh... c'mon now... {clutching sides in laughter... almost fell out of chair}, that developer is doing the best (s)he can...
Thanks for the Friday laugh...
Steve, you should start a "Darwin Award" forum... this should be the first entry. 😛
--Jeff Moden
Change is inevitable... Change for the better is not.
August 2, 2008 at 3:29 am
Well, not to give competition to Steve... OK, it won't, but there is
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
- Theodore Roosevelt
Author of:
SQL Server Execution Plans
SQL Server Query Performance Tuning
August 2, 2008 at 3:43 am
Alvin Ramard (8/1/2008)
I can't help but wonder if the view definition looks something like:create view vwProviderDirectoryReportWithAllServiceLocations
as
Select *
From
ProviderDirectoryReportWithAllServiceLocations
end
Or
create view vwProviderDirectoryReportWithAllServiceLocations
as
Select *
From
tbProviderDirectoryReportWithAllServiceLocations
to keep with the prefix style.
I think someone took the 'use stored procedures' rule just a little far.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
August 2, 2008 at 3:46 am
Grant Fritchey (8/2/2008)
Well, not to give competition to Steve... OK, it won't, but there is
I love that blog. Just wish it was updated more often.
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
August 2, 2008 at 8:43 am
What I think is interesting about that blog, is that it's the person writing the blog who is sometimes the "dumbass". One guy wrote about the ol' turbo button prank trick he played on a developer who actually took the time to ask for help... that developer will never ask that DBA for help again and that's a real shame. The DBA was nothing but a BSOFH.;)
--Jeff Moden
Change is inevitable... Change for the better is not.
August 2, 2008 at 9:25 am
I thought much the same on that particular post, though there may be history that we don't know of. The other authors are fine (imho)
I think you'll appreciate the latest posting there. :hehe:
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
August 2, 2008 at 1:07 pm
Jeff Moden (8/2/2008)
The DBA was nothing but a BSOFH.;)
Uuuhh, ... "Big Stupid Old Fart-Head"?
[font="Times New Roman"]-- RBarryYoung[/font], [font="Times New Roman"] (302)375-0451[/font] blog: MovingSQL.com, Twitter: @RBarryYoung[font="Arial Black"]
Proactive Performance Solutions, Inc. [/font][font="Verdana"] "Performance is our middle name."[/font]
August 2, 2008 at 11:05 pm
rbarryyoung (8/2/2008)
Jeff Moden (8/2/2008)
The DBA was nothing but a BSOFH.;)Uuuhh, ... "Big Stupid Old Fart-Head"?
Heh... Ummm... no... what's your user name again? 😉
http://members.iinet.net.au/~bofh/bofh/bofh2.html
http://members.iinet.net.au/~bofh/
The "SO" stands for "SysOP"... you can figure out the rest from the links above. They're actually funny as all get out... 😛
--Jeff Moden
Change is inevitable... Change for the better is not.
August 3, 2008 at 1:18 am
Oh yeah, I remember that one from way back. Heh.
[font="Times New Roman"]-- RBarryYoung[/font], [font="Times New Roman"] (302)375-0451[/font] blog: MovingSQL.com, Twitter: @RBarryYoung[font="Arial Black"]
Proactive Performance Solutions, Inc. [/font][font="Verdana"] "Performance is our middle name."[/font]
August 4, 2008 at 8:35 pm
Heh... I just saw this code posted on our very own forums as part of some dynamic SQL... link withheld to protect the guilty... 😉
,CASE schedule.[letter_box_yn] WHEN ''Y'' THEN ''Y'' WHEN ''N'' THEN ''N'' END AS ''letter_box''
,CASE schedule.[continued_yn] WHEN ''Y'' THEN ''Y'' WHEN ''N'' THEN ''N'' END AS ''continued''
,CASE schedule.[subtitled_yn] WHEN ''Y'' THEN ''Y''WHEN ''N'' THEN ''N'' END AS ''subtitled''
--Jeff Moden
Change is inevitable... Change for the better is not.
Viewing 15 posts - 1 through 15 (of 23 total)
You must be logged in to reply to this topic. Login to reply