Hi Mynda
I used your table 4.15 to practice the unpivot as a case study. Then I added a sheet "New Repeating Rows-April 2023" with new data (assuming I receive the data in the same format each month).
I copied and paste the data into the "Dieneba-Repeating Rows" where I created the query but the new data does not appear. Can you help me with the use of the query to update a table with new data? How do you apply the query in this instance? I went through the first 3 videos in chapter 7 but it's rather confusing for me (the videos are not confusing just me I am finding it hard to grasp this). I am going over the videos again from scratch to keep practicing.
Regards
Dieneba
Hi Dieneba,
If you look at the Source step you can see the query is referring to the table called Tableau3. That table is on the sheet called Repeating Rows.
Your data on sheet "New Repeating Rows-April 2023" is in a table called Tableau36. You need to change the Source step of the query to reference Tableau36. You can just edit it in the formula bar. I cover ways to re-use queries in lesson 5.06.
Hope that helps. Let me know if you're still stuck.
Mynda
Hi Mynda
I checked the video but still not easy for me. These are the steps I took:
1- I went on request and connections
2- I click right on the mouse and select modify
3- I go to the source and change table 3 to 36.
The result is that I see the data from table 36 but not from 3. I still do not get the data from table 3 and 36
When I try to copy and paste the M code from the query (as per your video) to a new sheet I do not have the option to paste just to create a new group.
Hi,
I believe that what you are trying to do might not be covered in the course, but Mynda needs to confirm that.
In the attached file, I have adjusted the query to one that references its own previous output and adds the new items to it. It's not straight-forward and difficult to follow if you haven't seen/used this technique before. And you have to be careful with the Refresh button, because every time you press it the query will append whatever it finds in the New table to the Previous output.
In terms of your file, what happens is this:
Tableau3 is the original source that results in Tableau3_2 (the green one from PQ)
Now you have to manually change the Source of the query to Tableau3_2 and give the step another name. I called it "Previous".
Then you add a new Source step that points at the table with the new items, thus Tableau36.
And then, almost at the end you append the table from the #"Colonnes supprimées" step to the one from the "Previous" step.
Now you have added the new items to the previous items.
Hi Dieneba,
I think Riny may have misunderstood the question as it appears to me that you simply want to add another table to the query data source, as opposed to reference a table is it's own previous output. I'm making that assumption because Tableau3 and Tableau36 in your file are not Power Query outputs.
In which case, you want to get multiple tables from the current file. This is covered in lesson 3.02. I think you're struggling because you started the query with just one table, which can be done simply with Get Data > From Table/Range, but then you changed the goal posts and want to add more tables, which requires a different approach from the outset.
I hope that points you in the right direction.
Mynda