Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
Nahel88
Frequent Visitor

Copy Query

I have the following example of my data :

Col1        Col2                                                        Col3        Col4

s               1                                                               s             1

q              2                                                               q             2 

d                                                                                f             3

f               3                                                                h            4 

g

h              4 

j

 

 and i want to get only the rows that both Col1 and Col2 are existin other words Col3 and Col4. I need the Query to get such a result sorry im not that good in writing queries but im in need to get this one. 

 

1 ACCEPTED SOLUTION
Baskar
Resident Rockstar
Resident Rockstar

Hi buddy,

I will give you two ways
1. from Query editor.
Original TableOriginal Table









Using Filter to remove NullUsing Filter to remove NullModelling TableModelling Table


2. From Development Canvas

Table ViewTable ViewRemove the check mark inRemove the check mark inOr else Choose in filter "is not Blank"Or else Choose in filter "is not Blank"

View solution in original post

8 REPLIES 8
Baskar
Resident Rockstar
Resident Rockstar

Hi buddy,

I will give you two ways
1. from Query editor.
Original TableOriginal Table









Using Filter to remove NullUsing Filter to remove NullModelling TableModelling Table


2. From Development Canvas

Table ViewTable ViewRemove the check mark inRemove the check mark inOr else Choose in filter "is not Blank"Or else Choose in filter "is not Blank"

carinat
Advocate I
Advocate I

Do you want to keep col 1 and 2 or could you simply just filter out blank values in both columns?

I think Nahel wants to remove blanks values from columns 1 and 2 in order to obtain something similat columns 3 and 4.

 

Create your table with columns 1 and 2, under Filters (right pane), expand column 2 and select is not blank, apply the filtering and this should remove all blank values.

wonga
Continued Contributor
Continued Contributor

@Nahel88

 

Assuming columns 1 and 2 are one table and columns 3 and 4 are another table:

 

You can probably use the "Merge Queries" feature in Query Editor and select the common column between the two tables and the result will be only what's common between the two.

 

If my assumption is incorrect, please provide more context/information as to what you want to achieve.

Nahel88
Frequent Visitor

ya but merge only works with mached type columns and those are two different types so , i dont think thats ganna work 


@Nahel88 wrote:

ya but merge only works with mached type columns and those are two different types so , i dont think thats ganna work 


@Nahel88

 

According to the snapshots in your original post, I think you can conform the columns to same consitent data types. Afterwards, merge the queries.

Capture.PNG

Baskar
Resident Rockstar
Resident Rockstar

Hi Nahel let me know , what is the output u excpecting ?

the Col3 and Col4 so a 2 new Columns 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.