Viewing 15 posts - 1,501 through 1,515 (of 2,458 total)
DECLARE @issues TABLE(Issues varchar(5), Category char(1), IssueDate date);
INSERT @issues VALUES
('I1','A','1/1/2015'),
('I2','A','2/2/2015'),
('I3','B','2/1/2015'),
('I4','C','3/3/2015'),
('I5','B','4/3/2015'),
('I6','A','5/4/2015');
SELECT * FROM @issues;
SELECT
mo.m,
A = SUM(CASE WHEN Category = 'A' THEN 1 ELSE 0 END),
...
May 13, 2015 at 8:00 pm
RECOMPILE and Copying the parameter as a local variable will likely eliminate that possibility of parameter sniffing.
If you normally get 10-15K reads then it goes up to 1.5M reads,...
May 13, 2015 at 4:59 pm
You can apply what I'm going to show you to your data. If you want to prove that what you are recommending is faster then visual proof is often the...
May 13, 2015 at 4:48 pm
First, welcome to SQL Server Central! See the link in my signature line to the article on how to best ask questions here. The small amount of time it takes...
May 13, 2015 at 9:58 am
I don't understand from your explanation what that other table is doing for you.
Adding to what Bill said - why not remove all indexes and constraints from the table...
May 13, 2015 at 9:33 am
Hard to say, it could be a lot of things. What I can say for sure is splitting the data into more files will help and separating the ldfs and...
May 12, 2015 at 10:36 pm
I have nothing to add to this post except to say that I love the title, "Sum Help". It would be even better if the title was, "I need sum...
May 12, 2015 at 10:07 pm
Tac11 (5/12/2015)
SELECT DB_NAME(fs.database_id) AS [Database Name], mf.physical_name, io_stall_read_ms, num_of_reads,
CAST(io_stall_read_ms/(1.0 + num_of_reads) AS NUMERIC(10,1)) AS [avg_read_stall_ms],io_stall_write_ms,
num_of_writes,CAST(io_stall_write_ms/(1.0+num_of_writes) AS NUMERIC(10,1)) AS [avg_write_stall_ms],
io_stall_read_ms +...
May 12, 2015 at 12:14 pm
I love this article Dwain. Very good work as always. 5 stars from me. I particularly enjoy how your hierarchies example - very clever.
I do want to add -...
May 12, 2015 at 6:08 am
peter-757102 (5/12/2015)
I distinctly remember that in the past any function used in a constraint needed to be deterministic.
Querying a table violates that rule, obviously.
When did this...
May 12, 2015 at 5:49 am
Jeff Moden (5/11/2015)
Alan.B (5/11/2015)
If you are talking about...
May 11, 2015 at 2:50 pm
Jeff Moden (5/11/2015)
Alan.B (5/11/2015)
If you are talking about...
May 11, 2015 at 1:52 pm
spaghettidba (5/11/2015)
LIKE would do as well:
WHERE ex NOT LIKE '%[^A-G0-9]%'
... and would be better than what I posted. I have not finished my coffee this morning and need to do...
May 11, 2015 at 10:30 am
Yes and Yes no. If you post an example of what you are trying to do specifically we can provide a specific example.
If you are talking about doing something like...
May 11, 2015 at 10:06 am
Viewing 15 posts - 1,501 through 1,515 (of 2,458 total)