Viewing 15 posts - 16 through 30 (of 2,456 total)
For cleaner code you can leverage fnTally. Since fnTally leverages TOP, you can exploit row goals as Steve Collins mentioned above.
CREATE OR ALTER FUNCTION dbo.getYears(@year...
February 18, 2021 at 6:40 pm
I don't have a server handy at the moment but what you are looking for is in the REPORTSERVER.DBO.CATALOG
This has the RDL XML (Report Definitions) which you can query. To...
January 22, 2021 at 3:36 pm
@ Alan,
I'm honestly a little bit surprised that you're justifying a sort because it has a low row count. We know how that usually works out.
I was a little rushed...
December 27, 2020 at 8:17 pm
apart from the performance that is likely to be quite bad has errors on its construct
The Construct is a problem but I suspect the performance should be fine, STRING_SPLIT is...
December 26, 2020 at 1:21 am
there is currently no way to incrementally populate the table.
... a [Huge] fact table that gets regenerated nightly
This is a design/process issue more than a technical one. I'll put my...
December 8, 2020 at 6:28 pm
A couple things to consider. First, In SSMS 2019 the actual execution plan will show you how much time each portion of the query took. You don't need that here...
November 17, 2020 at 6:46 pm
Grab a copy of PatReplace8K and it should be easy to strip out what you need.
SELECT
pa.*,
Clean1 = CAST(ISNULL(pr.newString,0) AS FLOAT),
...
November 17, 2020 at 6:20 pm
What you posted is similar to my first version of this except that I use my ngrams function to generate the tally table. Here's a simplified...
August 4, 2020 at 3:41 am
Agreed. I said similar in this post from above...
I missed this.
The difference is that I did the split using an indexed view. This way the split only happens once,...
August 3, 2020 at 6:46 pm
Just as a side note, depending on how often your columns are updated/modified, you can always split the string ahead of time using a permanent tally table like...
August 3, 2020 at 6:38 pm
Just as a side note, depending on how often your columns are updated/modified, you can always split the string ahead of time using a permanent tally table like this:
August 3, 2020 at 1:51 am
I'm not seeing any code attached to your last post. What code are you talking about being "attached"?
Grrr...
/*********************************** PART #1...
August 1, 2020 at 1:51 am
UPDATED 20200803 at 9:30PM
Ok, 4 1/2 years later I have a something really good to show!
This code is from one of many articles in various phases of completion which I'll...
July 31, 2020 at 7:35 pm
Great article Steve. Really informative.
July 27, 2020 at 4:34 pm
I've just added CLR Regex Functions to our SQL Servers.
I'm trying to replace some of our less efficient string parsing TSQL functions with the new .Net CLR Regex Functions.
For things...
February 12, 2020 at 12:58 am
Viewing 15 posts - 16 through 30 (of 2,456 total)