Viewing 15 posts - 2,476 through 2,490 (of 4,085 total)
thomashohner (8/9/2016)
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 9, 2016 at 3:05 pm
Please post sample data and expected results as in the first link in my signature.
That being said, if you want to find a value base on the MAX/MIN of another...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 9, 2016 at 2:48 pm
Luis Cazares (8/9/2016)
It's not about one join being better than the other. It's about using the correct join for each query.Here's an explanation on how each join works.
http://www.codeproject.com/Articles/33052/Visual-Representation-of-SQL-Joins
+1 on this....
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 9, 2016 at 12:42 pm
tstagliano (8/9/2016)
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 9, 2016 at 12:28 pm
Okay, after looking at the other code posted, it looks like Lynn's code will work only with paths. My code will work with all directed acyclic graphs. A...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 8, 2016 at 11:39 am
Here are the two queries that I was alluding to. The first one starts with the original stakeholders and moves down the tree. Then you filter based on...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 8, 2016 at 11:12 am
You've rewritten a CASE statement in about as obscure a way as possible.
-- Your version
ISNULL(CAST(NULLIF(ISNUMERIC(@deposit), 1) AS money), @deposit)
-- The straightforward version
CASE WHEN ISNUMERIC(@deposit) = 1 THEN CAST(@deposit as money)...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 8, 2016 at 9:53 am
Hugo is right that my approach may have a lot of reads, but there is a modification to my approach that will have many fewer reads, but it first requires...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 5, 2016 at 1:55 pm
I'm getting frustrated. http://www.sqlservercentral.com/Forums/Topic1807080-391-1.aspx
Drew
Edited to place the bold tags outside of the url.
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 5, 2016 at 12:07 pm
sku370870 (8/5/2016)
drew.allen (8/5/2016)
sku370870 (8/5/2016)
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 5, 2016 at 12:02 pm
lmarkum (8/5/2016)
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 5, 2016 at 11:20 am
sku370870 (8/5/2016)
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 5, 2016 at 9:17 am
joanna.seldon (8/5/2016)
this works brill within my view
, ROW_NUMBER() OVER(PARTITION BY a.StudentID
ORDER BY CASE WHEN b.[VehicleType] = 'CAR' THEN 1...
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 5, 2016 at 8:08 am
Since you're on SQL 2012, look at LAST_VALUE.
Drew
Edited: Added hyperlink.
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 4, 2016 at 3:13 pm
Please provide sample data and expected results as listed in the first link in my signature.
Drew
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
August 4, 2016 at 12:57 pm
Viewing 15 posts - 2,476 through 2,490 (of 4,085 total)