+ Reply to Thread
Results 1 to 3 of 3

Problem with Grouping Dates in a Pivot table

  1. #1
    Registered User
    Join Date
    06-26-2013
    Location
    Edinburgh, UK
    MS-Off Ver
    Excel 2016
    Posts
    43

    Problem with Grouping Dates in a Pivot table

    Hello

    With help from this forum I am using a formula below to populate a column with dates which are recognised as dates in a pivot table...

    =DATE(VALUE(MID(AN40,C40+1,4)),VALUE(LEFT(AN40,B40-1)),VALUE(MID(AN40,B40+1,C40-B40-1)))

    This works but unfortunately when I try to Group the data in the Pivot table by month/year it cannot group the data... maybe because there are some blank cells ?

    So I tried adding a 'filler' date in the year 1900 that I could then just filter out in the pivot table but it doesn't work .... maybe because the filler date is not formatted as a date?

    =IFERROR(DATE(VALUE(MID(AN40,C40+1,4)),VALUE(LEFT(AN40,B40-1)),VALUE(MID(AN40,B40+1,C40-B40-1))),"01/01/1900")

    I would appreciate help on how to fill the blanks in such a way that the Pivot table field can be Grouped by Year/Month etc.. (Ideally I wouldn't use a 'filler' date but my understanding is that blank cells prevent the pivot table field being Grouped)

    Thank you

  2. #2
    Forum Expert Roel Jongman's Avatar
    Join Date
    03-28-2015
    Location
    Netherlands
    MS-Off Ver
    Office 365
    Posts
    1,483

    Re: Problem with Grouping Dates in a Pivot table

    the double quotes around anything tell excel to read it as text. So replace "01/01/1900" by Date(1900,1,1) to make the grouping work.
    I think even putting a plain 0 will suffice for grouping for excel dates are nothing more than formatted numbers.

  3. #3
    Registered User
    Join Date
    06-26-2013
    Location
    Edinburgh, UK
    MS-Off Ver
    Excel 2016
    Posts
    43

    Re: Problem with Grouping Dates in a Pivot table

    Thank you Roel - this worked fine

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. [SOLVED] Grouping Dates in Pivot Table
    By kersplash in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 01-17-2018, 01:27 AM
  2. Grouping by dates- Pivot table-
    By thursday140 in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 09-22-2016, 08:15 AM
  3. Grouping Dates-Pivot Table
    By demice in forum Excel Charting & Pivots
    Replies: 5
    Last Post: 06-07-2013, 06:43 AM
  4. Grouping Dates in Excel Pivot Table
    By mskennedy in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 02-13-2013, 09:33 AM
  5. grouping dates in pivot table
    By lintcoop in forum Excel General
    Replies: 8
    Last Post: 01-09-2009, 03:29 PM
  6. [SOLVED] Grouping dates in a pivot table
    By Fred Smith in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 03-14-2006, 10:10 PM
  7. grouping dates in pivot table
    By Charles Maronski in forum Excel General
    Replies: 2
    Last Post: 05-21-2005, 09:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1