Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Columns with the same name show incorrectly in the results #37

Open
benb1n opened this issue May 15, 2023 · 1 comment
Open

Columns with the same name show incorrectly in the results #37

benb1n opened this issue May 15, 2023 · 1 comment

Comments

@benb1n
Copy link

benb1n commented May 15, 2023

If I run an Athena query that returns columns with the same name, only the last column in the list is returned and its value is duplicated for each column with the same name.

Example query:

select w.name, s.name
from warehouses w
join shipments s on w.id = s.warehouseid
order by s.name
limit 10;

Results:
image

This should have returned the warehouse name in the first result column and the shipment name in the second, but it returned the shipment name for both. It appears to be a mapping issue when the results are returned.

An easy fix is to just alias the column names to make them unique, but it would be great to fix the root issue. I'm interested in contributing a fix for this and possibly helping with other issues on this project, but I would like confirmation that this project is still being maintained before I invest time and effort. Love what you've done so far! It's very helpful, and I'd love to see it become the go-to tool for Athena for non-console access if you want to use VS Code.

@JohniMichels
Copy link
Contributor

@benb1n we work on this driver from time to time, that is a known issue and it has todo on how the underlying tool works, since it uses a dict as a mapper for the rows, we always update values on those records when a column with the same name show again. I think we won't solve that specific issue since there is an easy workaround using different alias on the query.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants