• 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

Power Query - Include specific sections of the report based on a title of the specific cell reference and stop when there is a blank row. |Power Query|Excel Forum|My Online Training Hub

You are here: Home / Power Query - Include specific sections of the report based on a title of the specific cell reference and stop when there is a blank row. |Power Query|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 ForumPower QueryPower Query - Include specific sec…
sp_PrintTopic sp_TopicIcon
Power Query - Include specific sections of the report based on a title of the specific cell reference and stop when there is a blank row.
Avatar
Jason Wier
Member
Members
Level 0
Forum Posts: 23
Member Since:
September 14, 2021
sp_UserOfflineSmall Offline
1
September 14, 2021 - 8:25 am
sp_Permalink sp_Print

Good day, 

I have a file that has sections separated by blank rows and merged columns in one worksheet.

want to use PowerQuery to pull out specific sections of the report based on a title of the specific cell reference and stop when there is a blank row.

Then repeat this process for a subsequent section in the worksheet.

Please see attached pic for details.

[Image Can Not Be Found]

Avatar
Catalin Bombea
Iasi, Romania
Admin
Level 10
Forum Posts: 1824
Member Since:
November 8, 2013
sp_UserOfflineSmall Offline
2
September 14, 2021 - 2:17 pm
sp_Permalink sp_Print

Hi Jason,

Nothing attached.

Rather than a picture, can you create a file with sample data? Will be much easier to help you.

Avatar
Alan Sidman
Steamboat Springs, CO
Member
Members


Trusted Members
Level 0
Forum Posts: 149
Member Since:
October 18, 2018
sp_UserOfflineSmall Offline
3
September 14, 2021 - 4:23 pm
sp_Permalink sp_Print

crossposted:  https://www.mrexcel.com/board/.....e.1181744/

Avatar
Jason Wier
Member
Members
Level 0
Forum Posts: 23
Member Since:
September 14, 2021
sp_UserOfflineSmall Offline
4
September 14, 2021 - 10:22 pm
sp_Permalink sp_Print sp_EditHistory

Please see attached

Avatar
Catalin Bombea
Iasi, Romania
Admin
Level 10
Forum Posts: 1824
Member Since:
November 8, 2013
sp_UserOfflineSmall Offline
5
September 15, 2021 - 2:00 am
sp_Permalink sp_Print sp_EditHistory

In the attached file, change the path to your sample file in the "Test" query.

Basically, the idea is to add a new column to identify the target headers, fill down that column then remove nulls. Grouping by that custom column will create a table with 2 rows, with data separated for Failed and Manual. The tables are extracted into 2 separate queries loaded to sheets.

Next time, please don't forget to add links to other sites where you have posted your question, nobody wants to waste time solving a problem that was already solved elsewhere, cross posting may potentially be a free time waste for many enthusiasts.

Welcome to our forum!

Avatar
Jason Wier
Member
Members
Level 0
Forum Posts: 23
Member Since:
September 14, 2021
sp_UserOfflineSmall Offline
6
September 16, 2021 - 11:04 am
sp_Permalink sp_Print

This was very good information. Thank you

I found Ruth's video that helped me create an index column and use the following to dynamically find "Failed Transactions" - the first section of the report that I need. I'll promote this row to headers.

Dynamically find header rows and promote them in Power Query - YouTube

I'll promote this row to headers.

 

My current issue now is this...

I need to keep the data under "Failed Transactions" until the FIRST blank row, AND then delete all the cells after this first blank row ("Manual Transaction" will come after this blank row, which I want to delete all these rows and I'll make this section its own query as you suggested).

Any suggestions?

Avatar
Catalin Bombea
Iasi, Romania
Admin
Level 10
Forum Posts: 1824
Member Since:
November 8, 2013
sp_UserOfflineSmall Offline
7
September 16, 2021 - 1:49 pm
sp_Permalink sp_Print

This was very good information. Thank you

Have you seen the file attached to my previous message? It has the solution as well,. not just "good information", why would you need other suggestions?

Avatar
Jason Wier
Member
Members
Level 0
Forum Posts: 23
Member Since:
September 14, 2021
sp_UserOfflineSmall Offline
8
September 16, 2021 - 9:47 pm
sp_Permalink sp_Print

Oh my goodness. I failed to review the attachment.  

This is just incredible!!!

You just made someone incredibly happy 

This is my first time using a forum.  I'm the biggest fan you have now.  

Thank you, thank you, thank you!  

Avatar
Catalin Bombea
Iasi, Romania
Admin
Level 10
Forum Posts: 1824
Member Since:
November 8, 2013
sp_UserOfflineSmall Offline
9
September 17, 2021 - 4:37 am
sp_Permalink sp_Print sp_EditHistory

Great, glad to hear you're happy.

Please mark the topic on other forums where you posted this question as solved, to stop them from spending time on your question.

Avatar
Jason Wier
Member
Members
Level 0
Forum Posts: 23
Member Since:
September 14, 2021
sp_UserOfflineSmall Offline
10
September 17, 2021 - 10:56 am
sp_Permalink sp_Print
  1. Sorry about the "cross" questions. I had no idea that the forums are so related. I'll make sure not to do that again. 

Again, you are tremendously appreciated!

Avatar
Jason Wier
Member
Members
Level 0
Forum Posts: 23
Member Since:
September 14, 2021
sp_UserOfflineSmall Offline
11
September 19, 2021 - 3:40 am
sp_Permalink sp_Print

Follow-up question: 

I understand now how you created the "Test" query. 

But how do I create the two new queries for "Failed" and "Manual"?

 

Test-2-Question.jpgImage Enlarger

[Image Can Not Be Found][Image Can Not Be Found]

sp_PlupAttachments Attachments
  • sp_PlupImage Test-2-Question.jpg (25 KB)
Avatar
Catalin Bombea
Iasi, Romania
Admin
Level 10
Forum Posts: 1824
Member Since:
November 8, 2013
sp_UserOfflineSmall Offline
12
September 19, 2021 - 1:46 pm
sp_Permalink sp_Print

Just start a new blank query with this formula:

= Table.SelectRows(Test, each _[Custom]="Failed")

(replace "Failed" with "Manual" for the other one)

Then apply the other steps I did in the sample file.

sp_Feed
Go to top
Forum Timezone: Australia/Brisbane
Most Users Ever Online: 245
Currently Online: Geoff McClure, Riny van Eekelen, David Jernigan, Cassie Bernier
Guest(s) 9
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: 215
A.Maurizio: 202
Aye Mu: 201
jaryszek: 183
Newest Members:
Abisola Ogundele
MARTYN STERRY
Rahim Lakhani
Ngoc Qui Nguyen
Clement Mansfield
Rose .
Bindu Menon
Baruch Zemer
Purple RainbowBenefactor
MOTH Junkie
Forum Stats:
Groups: 3
Forums: 24
Topics: 6350
Posts: 27773

 

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