Viewing 15 posts - 3,331 through 3,345 (of 3,479 total)
Never use someone else's code that you don't understand, because if it breaks, you're on the hook.
Try Ola Hallengren's stuff.
August 22, 2013 at 10:41 am
Why not use EXISTS and something like t1.FK<>t2.FK to check for the existence of two records?
By definition, EXISTS stops as soon as it evaluates to True.
Sean's right - honey beats...
August 22, 2013 at 10:39 am
Thanks HappyCat,
worked a charm!
Pieter
August 22, 2013 at 12:09 am
DECLARE @Count INT
SELECT * FROM MyTABLE WHERE...;
SET @Count = @@ROWCOUNT;
IF @Count>0
BEGIN
-- call SendDBMail or whatever you want and e-mail the report.
END
August 20, 2013 at 8:51 pm
Did you try using JOIN()?
=JOIN(Parameters!prmMultiValuedParam.Value,", ") & " " & Parameters!prmNonMultiValuedParam.Value
Use JOIN for the parameters that allow multiple values and then just
Parameters!ParamName
for the rest.
August 19, 2013 at 10:34 pm
LOL... I wish it only took coffee to wake me up.
The graph works. Might not be the best T-SQL to get me there, but it gets the job done....
August 19, 2013 at 11:30 am
Getting closer, I think.... really should have heeded my professor's advice and used a smaller dataset, but anyway! I think this is right
SELECT ProtocolNo
, WeekNumber
, Goal
-- ADD RTGoal here
,...
August 18, 2013 at 4:31 pm
Easy button! <CLICK!> Thanks, Jeff!
For other poor noobs like me, here's at least the first part of the running total.
SELECT ProtocolNo
, WeekNumber
, Goal
, SUM(Goal) OVER (PARTITION BY ProtocolNo...
August 18, 2013 at 12:32 pm
MM,
super cool... got it to work... now to sort out the parameter stuff!
Pieter
August 12, 2013 at 8:54 pm
I was afraid I was going to have to use that. No way to pass a parameter directly to a stored procedure through the GUI. No big surprise...
August 12, 2013 at 3:02 pm
I was going to add that viewing an entire table could be a bad idea. Imagine viewing the entire contents of a Fact table in a Data Warehouse with...
August 12, 2013 at 12:41 pm
Thanks Koen, at least now I know if I need to upgrade yet. (Apparently not!)
One sort of follow-up question... I was looking on here for how to execute...
August 12, 2013 at 12:39 pm
Use ROW_NUMBER().
This is close, but not quite right...
WITH SomeNumbers AS
(
SELECT c1, c2,
ROW_NUMBER() OVER (ORDER BY c1) AS RowNumber
FROM #t1
)
SELECT x.c1
, x.c2
, x.PrevC2
, x.c2-COALESCE(x.PrevC2,0) AS Delta
FROM (SELECT s1.c1
, s1.c2
--, s1.RowNumber
--, s2.c1...
August 10, 2013 at 7:34 pm
Viewing 15 posts - 3,331 through 3,345 (of 3,479 total)