Forum Discussion
Python requests working in Power Query not when loaded in Data Model
Hi, Anonymous
You can launch your external Python IDE from Power BI Desktop and have your data automatically imported and displayed in the Python IDE. From there, you can modify the script in that external Python IDE, then paste it back into Power BI Desktop to create Power BI visuals and reports.
Please refer to the following documentation on using Python in Power BI to see if it helps you.
Use an external Python IDE with Power BI - Power BI | Microsoft Docs
Using Python in Power BI Power Query Editor - Power BI | Microsoft Docs
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi Charlotte v-zhangti ,
Sorry if there is a misunderstanding, editing the Python script is not an issue that I am having.
The issue is that there seems to be no way to consolidate dynamic parameters in a table that can be passed into Python.Execute(), without creating another table with Table.FromRecords() or similar, that also works in the report view. See below screenshots:
In the first image, it has clearly worked (the preview shows the Python output, a table from the API).
In the second image, after clicking "Close & Apply", the url is broken and no output shown.
2 things, why is this happening, and how do I best fix it?