Showing results for 
Search instead for 
Did you mean: 

Error updating data with gateway: Credential are required to connect to the SQL source.

The same report that works fine from desktop PBI app, do not work when published online.

When trying to update, i get the following error:



Until 2 weeks ago it worked fine.


I tried to reduce at minimum the variables to understand what could be the problem, and i found that the point is about building the query string to execute in power query, concatenating variables. But only in some case:


Depending how I set the concatenated variable to the static strings, it works on both the environments or only from desktop: 
variable1 = "" WORKS ALWAYS
variable1 = if 1=1 then "" else "" WORKS ONLY FROM DESKTOP
variable2 = "'" & "0" & "'" WORKS ALWAYS
variable2 = "'" & Number.ToText(0) & "'" WORKS ONLY FROM DESKTOP

I use the variable in power query, in the following way:


Origin = Sql.Database(Server, Database, [Query= "Select " & variable2 &", *, " & variable 1 & " from dbo.Table"]


(These examples are real tests made after I became desperate)

Status: New
Community Support



That seems to work fine for me. You may also create a support ticket for assistance if necessary.