[Athena Engine V3] INVALID_VIEW: line 5:8: Failed analyzing stored view 'cadatasource.cadb.caview': line 16:6: Table 'AWSDataCatalog.mydb.mytable' does not exist
0
We've set up cross account access as described here. All our cross account queries have been working up to now.
But now we've set up a workgroup that uses Athena engine V3. Our queries have generally worked fine in this workgroup except for some cross account queries. We get errors similar to
INVALID_VIEW: line 5:8: Failed analyzing stored view 'cadatasource.cadb.caview': line 16:6: Table 'AWSDataCatalog.mydb.mytable' does not exist
We see no errors from these queries when we run them in our primary (engine V2) workgroup. It appears that Athena engine V3 swaps the default data source (AWSDataCatalog in this case) from our account into the cross account view (cadatasource.cadb.caview). It assumes the tables that the cross account view references are in the default data source in the account from which we are issuing the query instead of the actual data source of the view in the other account.