• 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
  • Blog
  • Excel Webinars
  • Excel Forum
    • Register as Forum Member

Merged Query - Repeated Values|Power Query|Excel Forum|My Online Training Hub

You are here: Home / Merged Query - Repeated Values|Power Query|Excel Forum|My Online Training Hub

vba course banner

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 ForumPower QueryMerged Query - Repeated Values
sp_PrintTopic sp_TopicIcon
Merged Query - Repeated Values
Avatar
Zach Predmore

New Member
Members
Level 0
Forum Posts: 2
Member Since:
October 19, 2018
sp_UserOfflineSmall Offline
1
October 19, 2018 - 3:18 am
sp_Permalink sp_Print

Hello - I am very new to PQ so apologies if this is a very basic question.  I am attempting to merge data from two tables, one used for actual time spent and another for budgeted time using the task as the link between the tables.  I am running into the following situation:

Actual Hours (Table 1):

Task A - Assistant - 15 hours

Budgeted Hours (Table 2):

Task A - Assistant - 20 hours

Task A - Manager - 30 hours

Task A - Director - 5 hours

Merged Query:

Task A - Assistant 15 hours (Actual) and 20 hours (budgeted)

Task A - Assistant 15 hours (Actual) and 30 hours (budgeted)

Task A - Assistant 15 hours (Actual) and 5 hours (Budgeted)

So as you can see my actuals are being duplicated for each different position that was budgeted on a given task when only one instance of the actuals is correct.

Thank you for any help.

Zach

sp_AnswersTopicSeeAnswer See Answer
Avatar
Alan Sidman
Steamboat Springs, CO
Member
Members


Trusted Members
Level 0
Forum Posts: 150
Member Since:
October 18, 2018
sp_UserOfflineSmall Offline
2
October 19, 2018 - 7:32 am
sp_Permalink sp_Print

Suggest you upload sample worksheets with tables so that we can test and analyze and offer solution.

Avatar
Mynda Treacy
Admin
Level 10
Forum Posts: 4517
Member Since:
July 16, 2010
sp_UserOfflineSmall Offline
3
October 19, 2018 - 9:02 am
sp_Permalink sp_Print

Hi Zach,

As Alan said, it makes it much clearer, quicker and easier if you can attach a sample file. Thankfully your example was relatively easy and I had a few spare minutes so I created a mock up Excel file for you.

In the attached file you'll see in the 'Source' step of the 'merge1' query that I selected the two 'Task' columns and then selected the two 'Role' columns to match. Hold CTRL to select multiple columns. You'll see Power Query has a 1 and 2 notation on the column headers.

Hope that points you in the right direction.

Mynda

sp_AnswersTopicAnswer
Answers Post
Avatar
Zach Predmore

New Member
Members
Level 0
Forum Posts: 2
Member Since:
October 19, 2018
sp_UserOfflineSmall Offline
4
October 20, 2018 - 12:24 am
sp_Permalink sp_Print

That did it, thank you!  I had to play around with the different join types too but was able to get it straightened out.  Thanks again.

sp_Feed
Go to top
Forum Timezone: Australia/Brisbane
Most Users Ever Online: 245
Currently Online:
Guest(s) 8
Currently Browsing this Page:
1 Guest(s)
Top Posters:
SunnyKow: 1432
Anders Sehlstedt: 873
Purfleet: 414
Frans Visser: 346
David_Ng: 306
lea cohen: 222
Jessica Stewart: 218
A.Maurizio: 202
Aye Mu: 201
jaryszek: 183
Newest Members:
Gilbert Lemek
Ashleigh Farquharson
Jayz Luu
Fred Smith
Charles DeGraffenreaid
Cathi Giard
Sarah Young
Henry Delgado
Alita Nieuwoudt
KL KOH
Forum Stats:
Groups: 3
Forums: 24
Topics: 6360
Posts: 27812

 

Member Stats:
Guest Posters: 49
Members: 32340
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.