• Skip to main content
  • Skip to header right navigation
  • Skip to site footer

My Online Training Hub

Learn Dashboards, Excel, Power BI, Power Query, Power Pivot

  • Courses
  • Pricing
    • Free Courses
    • Power BI Course
    • Excel Power Query Course
    • Power Pivot and DAX Course
    • Excel Dashboard Course
    • Excel PivotTable Course – Quick Start
    • Advanced Excel Formulas Course
    • Excel Expert Advanced Excel Training
    • Excel Tables Course
    • Excel, Word, Outlook
    • Financial Modelling Course
    • Excel PivotTable Course
    • Excel for Customer Service Professionals
    • Excel for Operations Management Course
    • Excel for Decision Making Under Uncertainty Course
    • Excel for Finance Course
    • Excel Analysis ToolPak Course
    • Multi-User Pricing
  • Resources
    • Free Downloads
    • Excel Functions Explained
    • Excel Formulas
    • Excel Add-ins
    • IF Function
      • Excel IF Statement Explained
      • Excel IF AND OR Functions
      • IF Formula Builder
    • Time & Dates in Excel
      • Excel Date & Time
      • Calculating Time in Excel
      • Excel Time Calculation Tricks
      • Excel Date and Time Formatting
    • Excel Keyboard Shortcuts
    • Excel Custom Number Format Guide
    • Pivot Tables Guide
    • VLOOKUP Guide
    • ALT Codes
    • Excel VBA & Macros
    • Excel User Forms
    • VBA String Functions
  • Members
    • Login
    • Password Reset
  • Blog
  • Excel Webinars
  • Excel Forum
    • Register as Forum Member

Issues with GETPIVOTDATA|General Excel Questions & Answers|Excel Forum|My Online Training Hub

You are here: Home / Issues with GETPIVOTDATA|General Excel Questions & Answers|Excel Forum|My Online Training Hub
Avatar
sp_LogInOut Log In sp_Registration Register
sp_Search Search
Advanced Search|Last Search Results
Search
Forum Scope




Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
sp_Search Search
sp_RankInfo
Lost password?
sp_CrumbsHome HomeExcel ForumGeneral Excel Questions & Answe…Issues with GETPIVOTDATA
sp_PrintTopic sp_TopicIcon
Issues with GETPIVOTDATA
Avatar
Anders Sehlstedt
Eskilstuna, Sweden

VIP
Members


Trusted Members
Level 3
Forum Posts: 870
Member Since:
December 7, 2016
sp_UserOfflineSmall Offline
1
November 8, 2018 - 7:42 am
sp_Permalink sp_Print

Hello,

As I try to show in attached file, I have noticed that when using the GETPIVOTDATA function to get data from a Pivot Table where the source data has been added to the data model I get the #Ref error. I have searched but can't find any explanation for this "error". Anyone here who can tell more about this issue?

Br,
Anders

sp_AnswersTopicSeeAnswer See Answer
Avatar
Frans Visser
Duivendrecht (near Amsterdam) - The Netherlands

VIP
Members
Level 2
Forum Posts: 346
Member Since:
April 21, 2015
sp_UserOfflineSmall Offline
2
November 8, 2018 - 8:00 am
sp_Permalink sp_Print

Hi Anders, I'm not sure if I understand what you mean in the sheet by 'adding data'. I suppose extra rows with data in the columns A-C.

When I do that and refresh the pivottables I see the left one does well and the right one doesn't, as you describe.

However when I make a new GETPIVOTDATA formula for that table, it works fine and it keeps on working with new data afterwards.

So maybe something by incident not good in that specific table?

I copied the one in columns E:L downwards and that works also fine with a copy from the formula in E12.

The formula is a bit a bare version of the complete GETPIVOTDATA, so maybe there is another reason, but I'm not sure about that.

Frans

Avatar
Frans Visser
Duivendrecht (near Amsterdam) - The Netherlands

VIP
Members
Level 2
Forum Posts: 346
Member Since:
April 21, 2015
sp_UserOfflineSmall Offline
3
November 8, 2018 - 8:02 am
sp_Permalink sp_Print

Here are my examples, maybe it helps, don't know.

Frans

sp_AnswersTopicAnswer
Answers Post
Avatar
Anders Sehlstedt
Eskilstuna, Sweden

VIP
Members


Trusted Members
Level 3
Forum Posts: 870
Member Since:
December 7, 2016
sp_UserOfflineSmall Offline
4
November 8, 2018 - 9:44 am
sp_Permalink sp_Print

Thanks Frans,

Seems the "rules" of how to use GETPIVOTDATA differs between a regular Pivot Table and a Power Pivot Table. I need to read more about this, but you gave me the answer in your example file.

The difference is that I wrote my formula as =GETPIVOTDATA("Sales",N3), which works fine with a regular Pivot Table, but apparently not with a Pivot Table where the data has been added to the data model, such Pivot Table is apparently regarded as a Power Pivot Table.

The formula you wrote is =GETPIVOTDATA("[Measures].[Sum of Sales]";$N$3) and that works. I changed my original formula to =GETPIVOTDATA("[Measures].[Sales]";N3), but I still got an error. When adding the text "Sum of" in the [Sales] section, then it works fine.

Seems I need to go back to the Power Pivot course to see what I apparently missed out.

Br,

Anders

Avatar
Frans Visser
Duivendrecht (near Amsterdam) - The Netherlands

VIP
Members
Level 2
Forum Posts: 346
Member Since:
April 21, 2015
sp_UserOfflineSmall Offline
5
November 9, 2018 - 6:34 am
sp_Permalink sp_Print

Thanks Anders. Actually I didn't write the formula. Just clicked on the total of the right pivottable. Excel gives you the proper formula back. You can customize that one depending on which data you want to show, but I thought you needed the grand total so I did it this way.

I liked the course here from John Michaloudis, although it used the old versions of Excel (don't know how that is at this moment).

And you can certainly pick up some good things from him on this formula!

Frans

Avatar
Anders Sehlstedt
Eskilstuna, Sweden

VIP
Members


Trusted Members
Level 3
Forum Posts: 870
Member Since:
December 7, 2016
sp_UserOfflineSmall Offline
6
November 9, 2018 - 8:23 am
sp_Permalink sp_Print

Hi Frans,

Well, this gave me some lessons learned. I previously thought that you only got a Power Pivot table when you connected two or more tables with relationships, but so it is not. Time to dig in again into chapter 8 in the Power Pivot course.

/Anders

sp_Feed
Go to top
Forum Timezone: Australia/Brisbane
Most Users Ever Online: 245
Currently Online: Philip Treacy, Ngoc Tinh, Riny van Eekelen, Alexandra Radu, Monique Roussouw, michael serna
Guest(s) 9
Currently Browsing this Page:
1 Guest(s)
Top Posters:
SunnyKow: 1432
Anders Sehlstedt: 870
Purfleet: 412
Frans Visser: 346
David_Ng: 306
lea cohen: 219
A.Maurizio: 202
Jessica Stewart: 202
Aye Mu: 201
jaryszek: 183
Newest Members:
michael serna
mashal sana
Tiffany Kang
Leah Gillmore
Sopi Yuniarti
LAFONSO HERNANDEZ
Hayden Hao
Angela chen
Sean Moore
John Chisholm
Forum Stats:
Groups: 3
Forums: 24
Topics: 6215
Posts: 27248

 

Member Stats:
Guest Posters: 49
Members: 31897
Moderators: 3
Admins: 4
Administrators: Mynda Treacy, Philip Treacy, Catalin Bombea, FT
Moderators: MOTH Support, Velouria, Riny van Eekelen
© Simple:Press —sp_Information

Sidebar

Blog Categories

  • Excel
  • Excel Charts
  • Excel Dashboard
  • Excel Formulas
  • Excel PivotTables
  • Excel Shortcuts
  • Excel VBA
  • General Tips
  • Online Training
  • Outlook
  • Power Apps
  • Power Automate
  • Power BI
  • Power Pivot
  • Power Query
microsoft mvp logo
trustpilot excellent rating
Secured by Sucuri Badge
MyOnlineTrainingHub on YouTube Mynda Treacy on Linked In Mynda Treacy on Instagram Mynda Treacy on Twitter Mynda Treacy on Pinterest MyOnlineTrainingHub on Facebook
 

Company

  • About My Online Training Hub
  • Disclosure Statement
  • Frequently Asked Questions
  • Guarantee
  • Privacy Policy
  • Terms & Conditions
  • Testimonials
  • Become an Affiliate

Support

  • Contact
  • Forum
  • Helpdesk - For Technical Issues

Copyright © 2023 · My Online Training Hub · All Rights Reserved. Microsoft and the Microsoft Office logo are trademarks or registered trademarks of Microsoft Corporation in the United States and/or other countries. Product names, logos, brands, and other trademarks featured or referred to within this website are the property of their respective trademark holders.