+ Reply to Thread
Results 1 to 6 of 6

How to stop auto-sort when making pivot tables

  1. #1
    Registered User
    Join Date
    11-12-2009
    Location
    US
    MS-Off Ver
    Excel 2003
    Posts
    10

    How to stop auto-sort when making pivot tables

    Hi,

    When making a pivot table, Excel seems to automatically auto-sort my data. How do I stop this from happening?

    For example,
    I have data in quarters as in 1q2009,2q2009,3q2009,4q2009,1q2010,2q2010,3q2010,4q2010.

    But when I input the data in pivot tables, it comes out in 1q2009,1q2010,2q2009,2q2010. etc

    Thank you for help.

  2. #2
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: How to stop auto-sort when making pivot tables

    Excel does not see 1q2009 as a number to sort other than the 1, 2, 3, etc., on the front.

    Do you actually have dates in your data because a pivot table can group on quarters?

  3. #3
    Registered User
    Join Date
    11-12-2009
    Location
    US
    MS-Off Ver
    Excel 2003
    Posts
    10

    Re: How to stop auto-sort when making pivot tables

    Thanks for the reply.

    No, the data does not have dates.

  4. #4
    Forum Expert martindwilson's Avatar
    Join Date
    06-23-2007
    Location
    London,England
    MS-Off Ver
    office 97 ,2007
    Posts
    19,320

    Re: How to stop auto-sort when making pivot tables

    try renaming them to
    2009q1 2009q2 2009q3 2009q4 2010q1 2010q2 2010q3 2010q4
    "Unless otherwise stated all my comments are directed at OP"

    Mojito connoisseur and now happily retired
    where does code go ?
    look here
    how to insert code

    how to enter array formula

    why use -- in sumproduct
    recommended reading
    wiki Mojito

    how to say no convincingly

    most important thing you need
    Martin Wilson: SPV
    and RSMBC

  5. #5
    Forum Moderator jeffreybrown's Avatar
    Join Date
    02-19-2009
    Location
    Cibolo, TX
    MS-Off Ver
    Office 365
    Posts
    10,316

    Re: How to stop auto-sort when making pivot tables

    Well looks like Martin beat me to it, but since it took me awhile to come up with it I will still post.

    With 1q2009 in A1, in B1 try...

    =TEXT(LOOKUP(LEFT(A1,1),{"1","2","3","4"},{"1","4","7","10"})&"/"&SUBSTITUTE(MID(A1,2,1),"q",1)&"/"&MID(A1,3,4),"d/m/yyyy")+0

    Then format as date. This will put all the text you had into 1/1/20009, 1/4/2009, 1/7/2009, and 1/10/2009 which is the first day of the quarter.

  6. #6
    Registered User
    Join Date
    11-12-2009
    Location
    US
    MS-Off Ver
    Excel 2003
    Posts
    10

    Re: How to stop auto-sort when making pivot tables

    Thanks for the help. I appreciate it.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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