The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi,
I am trying to copy my Power Query which is working in Power Bi desktop into a data flow. Where the power query works in Desktop, it gives the following error when running the query in data flow online.
"Expression.Error: We cannot convert a value of type Table to type Text"
Is there a way to solve this expression error so I can load my dataset in the online data flow environment.
Below first part of the query
let // *** STEP 1: RETRIEVE SESSIONID *** #"1. Set up Session" = Xml.Tables(Web.Contents(pURL_Logon, [ Content=Text.ToBinary(XML_Session), Headers=[#"Content-Type" = "text/xml;charset=UTF-8"] ] )), ExpandedSession = Table.ExpandTableColumn(#"1. Set up Session", "Table", {"Name", "Table"}, {"Name.1", "Table"}), ExpandedSession2 = Table.ExpandTableColumn(ExpandedSession, "Table", {"Name", "Table"}, {"Name.2", "Table"}), ExpandedSession3 = Table.ExpandTableColumn(ExpandedSession2, "Table", {"SessionID", "AccessToken", "LogonResult", "nextAction", "cluster"}, {"SessionID", "AccessToken", "LogonResult", "nextAction", "cluster"}),
Thanks,
Leon
Solved! Go to Solution.
Thanks, I have build up the query again and now it works. However not with your proposed solutions, so that is a litte strange.
@Anonymous ,
This issue should be related to the return value can't be recongized by Xml.Tables() in power bi service. You may change your code using Web.Page() and use Web page option in dataflow instead and check if this issue persists.
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks, I have build up the query again and now it works. However not with your proposed solutions, so that is a litte strange.
I have added "{" in front of the "["now the error changed in the following:
"We encountered an error during evaluation. Details: Expression.Error: We cannot convert a value of type List to type Record. "