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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
fab196
Helper II
Helper II

how to fetch the values from the other table even there is no relation between two tables

Hi,

I have two tables nemely the data1 and data2

data1:                                                             

id saleslist
12323
222530
366224
455550
520550

 

data2:

categorystartstop
0-1800180
181-600181600

 

and result i wanted using powwer bi m query language(power query editor) is:

categorystartstoplist
0-180018023
181-600181600224
181-600181600530
181-600181600550

the above table data1 and data2 have no relationship between two table.but based on the data i want to fecth the values from data1 table into the data2 table .

for ex. In my data in data1 table have list column contains multiple values .and i want fetch this values into the data2 table based category column .like in tbale data1 the first row has 23 value in the list field and in the data2 table its among the 0-180 so it will come to the 0-180 category same for the others .if there are duplicates in the data1 list column then distinct will returend.

 

please help

 

@amitchandak 

@parry2k 

 

 

4 REPLIES 4
Greg_Deckler
Community Champion
Community Champion

@fab196 Easiest way would be to create a custom column in Table 1 using multiple if then else statements to get the same thing as your Category column in Table 2. Then you could just do a Merge query.

So like:

if [list] < 181 then "0-180"
else if [list] < 600 then "181-600"
else "something else"


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

hi,

thnaks for your promp reply but i have found the result using list function but in list if one of the value of column is null then its showing error
like in below data:

startend list
020list
2130list
31 error 

 

the result i wanted is that : for  ex supose start and stop is 0-20 then list fuction giving me a reange of values between 1 to 20 but in the third row of data the end column have one null value .eg for 31-null due to that it is  throwing an error so for that how to i get the list of range between greater than 31 and so on

Hi, @fab196 

Not clear.

Please show the current formula for the custom column you are using or a screenshot of it for further research.

 

Best Regards,
Community Support Team _ Eason

@Greg_Deckler please reply on above comment

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors