+ Reply to Thread
Results 1 to 3 of 3

Pivot Table - Date issue

  1. #1
    Registered User
    Join Date
    06-10-2014
    Posts
    21

    Pivot Table - Date issue

    Hi All,

    I'm sure similar threads have been posted regarding my query, so apologies if this has already been answered.

    I'm having a real issue getting data in a pivot table to sort correctly.

    We have a spreadsheet containing a log of any praise/complaints received and I am using a pivot table to format the data and to produce a pivot chart.

    The columns in the pivot table consist of the following.

    January 2019 1
    Praise 1
    February 2019 2
    Complaint 1
    Praise 1
    March 2019 2
    Complaint 1
    Praise 1

    The problem occurred when I added a new record for May 2019. When I refreshed the Pivot Table I was expecting to see the May 2019 entry at the bottom underneath march, but instead it was inserted at the top.

    I found some posts online that mentioned that it may be because it's formatted as text, which it is, but wouldn't May still appear under March in alphabetical order if that's the case?

    Any help would be appreciated.

    Thanks

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

    Re: Pivot Table - Date issue

    but wouldn't May still appear under March in alphabetical order if that's the case?
    yes, unless I have missed the memo the alphabet has not changed recently

    The issue could be as simple as that there is a space before the M of May, spaces are sorted before A.
    it can also be another (special) character in front of eighter may or the other values. Even it could be that some dates are true dates and others are text dates that will also affect sorting.

    also there if may 2019 is a true date then it is a number and numbers are also sorted before A / text.

    without seeing the file it is not possible to know the exact cause but "strange sorting" is due to inconsistencies in the datatable..

  3. #3
    Registered User
    Join Date
    06-10-2014
    Posts
    21

    Re: Pivot Table - Date issue

    Thanks for the reply Roel.

    I think I may have solved the problem.

    I have created a VBA front end which includes a reporting form. When the user selects a specific year to report on the relevant data is copied to a reporting sheet and the pivot tables are refreshed programmatically based on the new data. However, old entries within the pivot table were not being removed and I think this was causing the sorting inconsistency.

    I accessed the pivot table options and ensured that the "Number of items to retain per field" dropdown was set to none (it was set to automatic). This seemed to do the trick as the pivot table now sorts correctly each time it is refreshed.

+ 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] Issue with pre formatted date in pivot table (Cannot group that selection)
    By ppgab in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 02-25-2016, 12:22 PM
  2. Pivot table issue, I'm not able to capture new data, when table is updated
    By johnnyq113 in forum Excel Formulas & Functions
    Replies: 10
    Last Post: 08-26-2015, 05:01 PM
  3. Replies: 3
    Last Post: 02-10-2015, 03:46 PM
  4. Pivot Table Date Column Issue
    By Tejas.T in forum Excel Charting & Pivots
    Replies: 4
    Last Post: 05-13-2014, 12:52 AM
  5. Pivot table date format issue when drop down run on VBA - Excel 2003
    By NotBright in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-14-2014, 06:28 AM
  6. Pivot Table Date Update Issue - Please Help
    By ThierrySem in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-07-2013, 07:43 AM
  7. [SOLVED] Macro to update pivot item (date format) in pivot table to latest date from data source.
    By rocksan in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 08-10-2012, 03:18 AM

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