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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Regular Visitor

Using multiple tables/data to create a new data via R script

Hi all,


I'm a newbie PowerBI user and would like to get some help with the following scenario. Suppose I have data1 and data2 loaded into power BI through say, excel and sql. And I would like to have a data that takes in data1 and data2 as inputs, do some  complicated transformations and calculations via an R script, and have it as data3 in the report.  Does anyone know if this is possible?


So far the only way I found via searching is either just load data1 and data2 in the r script (instead of having them come from power BI). But I would like to avoid this approach due to various reasons.


One other way is to "transform" an existing data via R script but in that scenario I seem to only have acccess to a a single data (data1 or data2), not both. 


Any advice?



Community Support
Community Support

Hi @wwyws0000 ,

What do you mean "do some complicated transformations", if you connect data1 and data2 in import mode, you can do transformations or create another table based on data1 and data2 in Power Query.


Best Regards,
Community Support Team _ kalyj

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks for the reply. By "complicated transformations" I mean things that can't be done through joining, simple arithmetics, etc. 


Would you be able to give an example of a power query that uses data1 and data2 and sends them to an r script? say the r script is just  "doThisFunction(data1,data2)"

Helpful resources

Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City


Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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