Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
smithygreg
Starting Member
37 Posts |
Posted - 2008-10-15 : 14:05:24
|
Hey All..I have a query that calls a specific function 3 times on the same parameters. Is this bad? Is there a better way to do this..?Here is basically what I am doing...select rate*dbo.GetTotalValue(othervalue)from datatablejoin othertable on dbo.gettotalvalue(othervalue) >= minimumanddbo.gettotalvalue(othervalue) < maximum Is there any way to just make the call for dbo.gettotalvalue() once? Is SQL Server smart enough to not make the call twice? Will it make any difference?Thanks a whole bunch!Greg |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
|
|
|
|
|