Forum Replies Created

Viewing 15 posts - 46 through 60 (of 60 total)

  • RE: Cursor to Load two tables

    Thom A - Friday, July 14, 2017 10:06 AM

    I assume, by your post, you are trying to get the results you show...

  • RE: YTD in matrix in SSRS

    pietlinden - Wednesday, July 12, 2017 11:38 AM

    Only way I can think of getting this to work would be to add a...

  • RE: YTD in matrix in SSRS

    Papil - Monday, July 10, 2017 3:07 PM

    pietlinden - Monday, July 10, 2017 2:31 PM

  • RE: YTD in matrix in SSRS

    pietlinden - Monday, July 10, 2017 2:31 PM

    What if you did it using PowerPivot and DAX. There are functions for that. CLOSINGBALANCE...

  • RE: Missing months group by

    ChrisM@Work - Wednesday, June 21, 2017 8:33 AM

    Steve Jones - SSC Editor - Wednesday, June 21, 2017...

  • RE: Missing months group by

    ChrisM@Work - Tuesday, June 20, 2017 4:39 AM

    The next step is to construct the statement as a string so it can be...

  • RE: Missing months group by

    Joe Torre - Monday, June 19, 2017 2:25 PM


    WITH calendarMonths(FirstOfMonth)
    AS
    (SELECT DateAdd(mm, number, '20170101') FROM master.dbo.spt_values sv WHERE type='P')
    SELECT
     calendarMonths.FirstOfMonth
    FROM calendarMonths;

  • RE: Missing months group by

    ChrisM@Work - Monday, June 19, 2017 10:12 AM

    Other than making the batch dynamic, this should be very close:
    DROP TABLE #SummedData
    --...

  • RE: Missing months group by

    Papil - Monday, June 19, 2017 7:44 AM

    ChrisM@Work - Monday, June 19, 2017 7:06 AM

  • RE: Missing months group by

    ChrisM@Work - Monday, June 19, 2017 7:06 AM

    Papil - Friday, June 16, 2017 10:14 AM

  • RE: Missing months group by

    ChrisM@Work - Friday, June 16, 2017 9:33 AM

    Ta Phil 🙂

    Here's a correction to the hard-coded query, check that it's what you're looking...

  • RE: Missing months group by

    ChrisM@Work - Friday, June 16, 2017 4:51 AM

    You're going to need dynamic sql to get the month/year columns. Here's a query for...

  • RE: Missing months group by

    Jason A. Long - Thursday, June 15, 2017 8:44 PM

    Try this...

    IF OBJECT_ID('tempdb..#temp4', 'U') IS NOT NULL
    DROP TABLE #temp4;
    GO
    CREATE TABLE...

  • RE: Missing months group by

    Steve Jones - SSC Editor - Thursday, June 15, 2017 10:55 AM

    Your attachment is a pivot, which is odd. Is that what...

  • RE: Missing months group by

    Here is the table-
    CREATE TABLE #temp4(
     Bdate DATE
    ,Country VARCHAR(7)
    ,Type VARCHAR(4)
    ,P1  INT
    ,P2  INT

Viewing 15 posts - 46 through 60 (of 60 total)