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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
marwood
Advocate I
Advocate I

unable to create new dataflow with amazon athena connector

Update: The December 2023 release of the gateway is now available. I installed it and this error has resolved. I checked what code the UI is generating now, and there is a third argument being populated in the December release that wasn't present before:

Source = AmazonAthena.Databases("put your dsn here", null, []),

 

.....

 

When I try to create a new dataflow with the Amazon Athena connector I get this error: "An exception occurred: 3 arguments were passed to a function which expects between 1 and 2."

 

This happens right at the beginning, at the "Connect to data source" screen, before I can do anything in the power query editor.

 

This is in the service, and both premium and pro workspaces are affected. This started yesterday.

 

Existing dataflows still refresh with no errors. I can edit an existing dataflow and there is no problem. I can save changes and refresh. This error only happens when I try to create a new dataflow.

 

I restarted the VM I have the gateway on. I reinstalled the driver and the gateway. None of those helped.

1 ACCEPTED SOLUTION

I just checked for an update to the data gateway, and the December gateway release is now available. I installed it and this issue has been resolved.

 

I checked what code the UI now generates, and there is a third argument:

let
   Source = Amazon.Athena.Databases("[put your dsn here]", null, []),

 

So the third argument was added in the December release but the gateway wasn't made available at the same time.

View solution in original post

10 REPLIES 10
marwood
Advocate I
Advocate I

Update: after 3 calls with MS support they aren't going to help any further unless I install the gateway on the same domain where I use Power BI desktop, even though this problem is in the service. We aren't going to configure the AWS account to allow connections from my machine so the only other option would be to install Power BI on an EC2 instance, just so the support contractor can check their boxes before investigating whether the web UI is populating AmazonAthena.databases() with an extra argument.

 

The guy helping me was very patient but not knowledgeable about the Athena connector. He insisted that I install the gateway on my laptop even after I explained multiple times that there is no way to connect to the AWS account from my laptop. This entire experience was a huge waste of my time. I've been working with Power BI for 7.5 years so if MS wants me to continue with this process they'll find my consulting rate very reasonable.

 

The connection works and I can create new dataflows with a blank query. This problem occurs only when I use the web UI to create a new dataflow with the Amazon Athena connector. So I've spent enough time on this and I'm just going to use a blank query and manually enter code.

Thx for sharing. Same error will occur if gateway is installed on machine vs VM.

I just checked for an update to the data gateway, and the December gateway release is now available. I installed it and this issue has been resolved.

 

I checked what code the UI now generates, and there is a third argument:

let
   Source = Amazon.Athena.Databases("[put your dsn here]", null, []),

 

So the third argument was added in the December release but the gateway wasn't made available at the same time.

marwood
Advocate I
Advocate I

I've had a couple calls with MS support and they haven't figured it out yet. I'm guessing they're working through a flowchart. This is the workaround I've been using in the meantime:

  1. New dataflow
  2. Add new tables
  3. Blank query
  4. In the blank query, use:

 

 

let
  Source = AmazonAthena.databases("your data source name here", null),
  #"Navigation 1" = Source{[Name = "AwsDataCatalog", Kind = "Database"]}[Data],
  #"Navigation 2" = #"Navigation 1"{[Name = "your database name here", Kind = "Schema"]}[Data]
in
  #"Navigation 2"

 

 

This will get you a list of your tables, and you can go from there.

 

My stack isn't configured to allow a connection from desktop to Athena so we can't test the Athena connector from Power BI Desktop.

 

I'll update if/when MS figures this out. It definitely seems like a bug. My connection works when I use code in a blank query, all my existing dataflows refresh, but it seems like the UI is trying to send 3 arguments to AmazonAthena.databases(). If anyone else is having this issue, please also log a support ticket. If there are more reports that will help all of us get a faster resolution.

To be clear, which parts of the above are variables?

GilbertQ
Super User
Super User

Please let us know if it works.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

GilbertQ
Super User
Super User

Hi @marwood 

 

That sounds like a bug as it should go to the next screen. I would log a support ticket for them to have a look for you!





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

Thanks GilbertQ! I've created a support ticket. I got a response and they actually sent me the link to this post as a solution which may resolve my issue. LOL! Hopefully we can get this sorted out.

GilbertQ
Super User
Super User

Hi @marwood 

 

It sounds to me as if there is some refresh issue or a data source update that is causing the error. What happens if you take an existing data flow and copy the Power Query advanced code into the new data file? Does this still work? If it does work, then. there must be some new details in the new data flow, possibly create a new data flow and compare the code in the advanced query.





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!







Power BI Blog

Hi GilbertQ,

 

I tried copying the code from an existing dataflow and pasting into a blank query. This worked and I was able to refresh it. I also tried exporting the json for an existing dataflow and importing into a new dataflow. That worked too.

 

This error happens when I go to "Add new tables", select the Amazon Athena data source, and enter my DSN. I click next and this error happens before the editor opens. 

 

 

Helpful resources

Announcements
PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

Top Solution Authors
Top Kudoed Authors