Skip to main content
cancel
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.

Reply
FXFelix
Helper II
Helper II

Teradata refresh issue

Hello,

 

I have been using Power BI dataset refresh with Powershell for a long time, and everything works like a charm...but I am facing a new problem.

 

I have created two datasource with the same server Teradata, but with different users (and differents access rights).

I have a dataset connected to datasource1, and another dataset connected to datasource2.


When I try to refresh the second dataset from the service, everything is ok, but when I try to do it from our Powershell scripts, the refresh fails because it uses datasource1 rather than datasource2...

 

Does anybody face the same issue and find a workaround ?

 

Thanks for your help

1 ACCEPTED SOLUTION

Hello and thanks for the answer.

 

I found what was wrong in my api calls.

I was using the api "Datasets - Bind To Gateway"  (Datasets - Bind To Gateway - REST API (Power BI Power BI REST APIs) | Microsoft Docs) but by design :

Binds the specified dataset from the workspace to the specified gateway, optionally with a given set of data source IDs. If you don’t supply a specific data source ID, the dataset will be bound to the first matching data source in the gateway.

That was the explanation !

 

Maybe it will help future usages.

View solution in original post

2 REPLIES 2
v-shex-msft
Community Support
Community Support

Hi @FXFelix,

According to your decision, it seems like PowerShell has cached the credentials that you inputted at the first operations. When you work with the second operation which requires different credentials, PowerShell uses the cached one for authorization and it failed due to credentials not matching.

If that is the case, I think you may need to do some cache clear or sign-out operations before you do the second one.

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

Hello and thanks for the answer.

 

I found what was wrong in my api calls.

I was using the api "Datasets - Bind To Gateway"  (Datasets - Bind To Gateway - REST API (Power BI Power BI REST APIs) | Microsoft Docs) but by design :

Binds the specified dataset from the workspace to the specified gateway, optionally with a given set of data source IDs. If you don’t supply a specific data source ID, the dataset will be bound to the first matching data source in the gateway.

That was the explanation !

 

Maybe it will help future usages.

Helpful resources

Announcements
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

PBI_APRIL_CAROUSEL1

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.