Viewing 15 posts - 2,896 through 2,910 (of 3,500 total)
[SomeDateColumn]<=TODAY
September 10, 2014 at 7:34 am
what I did was to do a weird join. Say you have two CTEs, one for "Current Year" and one for "Previous Year". You can do a terrible...
September 9, 2014 at 10:19 pm
FWIW, sometimes people just don't know what an answerable question looks like (complete with sample data etc). I was sorely tempted to post a link to Jeff's article when...
September 9, 2014 at 10:03 pm
Jack,
Cool solution! After stepping away from what I was thinking before, I realized that I could use a CTE to do the thing... (and I saw you did that)....
September 9, 2014 at 6:11 pm
I got a start on the solution... hopefully this will send you in the right direction. If you have 2012, you can use LAG to compare. The only...
September 8, 2014 at 7:24 pm
Easiest way to do it is to open the report in design view. Do you not have rights to do that?
September 8, 2014 at 2:09 pm
My guess would be to create a PIVOT
This article walks you through it:
http://www.sqlservercentral.com/articles/pivot/62808/
Then once you have that, you should be able to append it to your destination table.
September 8, 2014 at 11:40 am
Can't you just publish it as a report part and reuse it that way?
September 5, 2014 at 5:27 pm
If what you're intending is to "explode" the range (say 1/1/2014 to 6/1/2014), then the easiest way is probably using an auxiliary Tally table. (Mine is called "Numbers" for...
September 4, 2014 at 12:19 pm
This worked... I changed a few field names, because they're reserved in T-SQL. Turns out this is a plain totals query.
SELECT Ticket, UserX, MIN(PriorityX)
FROM
(SELECT 'A' AS Ticket,
'ME' As...
September 3, 2014 at 1:56 pm
Before trying to build a data warehouse, I would definitely recommend reading Ralph Kimball's book. I have a really old copy of The Data Warehouse Toolkit. There are...
September 1, 2014 at 8:28 pm
If you really mean the current year as in YEAR(GETDATE()), then
=YEAR(Today())-1 is last year: 2013
=YEAR(Today())-2 is two years ago: 2012
August 28, 2014 at 7:21 am
It's a tablix on the outside (for the years) with a matrix inside (for the Totals by month for a single year). Because several years are in the...
August 28, 2014 at 6:55 am
In a word, use DATEADD().
for example...
=DateAdd("d",3,Today)
August 28, 2014 at 4:55 am
I can try to attach this thing... the fun part is that I had to do some voodoo to get all the dates to show up. Here's the query...
August 28, 2014 at 3:29 am
Viewing 15 posts - 2,896 through 2,910 (of 3,500 total)