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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Loop Function with all values from other table as parameter

Hi, im tryinng to do a Loop to invoke a function with all values from other table as parameter (many times as necessary), to clarify:

 

I have this table with people ID:

 

AlvaroNas_0-1643377656554.png

 

 and y have created my function to works with this ID's as parameter:

 

AlvaroNas_1-1643377706790.png

here is an example with the employee ID: 5894

AlvaroNas_2-1643377739871.png

 

So all i need to do is to generate a list than can automatically take all the values from the first table and one by one invoke the function and capture this data in the same query.

 

I tried to do my best with my english. Thank you very much for your help!

 

1 ACCEPTED SOLUTION
BA_Pete
Super User
Super User

Hi @Anonymous ,

 

Can't you just add a new custom column to your employee number table and enter your function as the column calculation?

PQ would automatically use the employee number on each row to calculate.

 

And your English is great 🙂

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




View solution in original post

2 REPLIES 2
BA_Pete
Super User
Super User

Hi @Anonymous ,

 

Can't you just add a new custom column to your employee number table and enter your function as the column calculation?

PQ would automatically use the employee number on each row to calculate.

 

And your English is great 🙂

 

Pete



Now accepting Kudos! If my post helped you, why not give it a thumbs-up?

Proud to be a Datanaut!




Anonymous
Not applicable

That works perfectly. Thank you very much!!!

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors