Viewing 15 posts - 3,241 through 3,255 (of 3,396 total)
I must have munged the SQL somewhere... it's not omitting the "next" courses for which a given student has some but not all of the prerequisites.
Here's the SQL I have,...
August 27, 2013 at 8:52 pm
okay, now to do something sane and create a subset of the two tables and make sure it works -- looks like it does, but I'm not sure yet. ...
August 27, 2013 at 10:33 am
So negate everything in parentheses, and then wrap a NOT around it (double negatives, my favorite!)
Makes sense... now, let me see if I can actually make it work!
Thanks!
August 26, 2013 at 8:48 pm
Since the course level should be fairly static (well, unless the prerequisites for a course are changed), I figured I would change things a little and store the computed level....
August 25, 2013 at 2:14 pm
LOL, thanks.
The funny thing was that I figured it out after posting a couple of times. I guess posting forces me to re-read a bunch of my code to...
August 25, 2013 at 10:56 am
Figured it out... I was joining on the wrong column in the CTE...
-- courses without prereqs
WITH PrereqsCTE (CourseID, Depth) AS
(
--- Anchor: courses without prerequisites
SELECT c.CourseID, 0 AS Lvl
FROM Course c
WHERE...
August 24, 2013 at 9:49 pm
Oh, super cool! Guess I gotta read (and re-read) Paul's article until I understand APPLY, then...
August 24, 2013 at 9:51 am
what if you use a different browser?
what if you print a different report?
August 22, 2013 at 11:22 am
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
Viewing 15 posts - 3,241 through 3,255 (of 3,396 total)