Excel 2019 Bible

(singke) #1

Chapter 40: Making Queries Work Together


4040


Full Outer This join tells Power Query to return all of the records from both queries
regardless of matching.
Inner This join tells Power Query to return only those records from both queries that have
matching values.
Left Anti This join tells Power Query to return only those records from the first query
that don’t match any of the records from the second query.
Right Anti This join tells Power Query to return only those records from the second query
that don’t match any of the records from the first query.

Merging queries
To understand the Merge feature better, let’s walk through an exercise that merges inter-
view questions and answers. In this walk-through, we’ll use the interview predefined que-
ries found in the Merging_Data.xlsx sample file.

As you can see in Figure 40.12, there are two existing queries in the Queries & Connections
pane: Questions and Answers. These queries represent the questions and answers from the
interview. The goal is to merge these two queries to create a new table showing the ques-
tions and answers side by side.

FIGURE 40.12
You need to merge the Questions and Answers queries into one table.

The Merge feature can be used only with existing queries. That is to say, no matter what kind of data sources you
have, you’ll need to import them into Power Query before you can use them in a merge.

Follow these steps to perform the merge:


  1. Click Data ➪ Get Data ➪ Combine Queries ➪ Merge (see Figure 40.13). This will
    activate the Merge dialog box.

Free download pdf