Skip to content

Conversation

calledit
Copy link

@calledit calledit commented Apr 9, 2023

When columns are renamed in sql queries, tracking the original table and column is not possible in the current implementation.

Example:

SELECT users.user_names AS username, posts.text AS post_text from users
LEFT INNER JOIN posts ON posts.user_id = users.id

In this query the original table will not be accessible, despite postgres acctually returning that information.

This patch adds two propertys to the fieldDesc struct and code to parse those fields from the postgres response.
Originally mentioned in #363

Copy link
Collaborator

@rafiss rafiss left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for the contribution. could you please add a test that confirms it works as expected?

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

Successfully merging this pull request may close these issues.

2 participants