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

fix: join and select mytable.* not working #6761

Merged
merged 2 commits into from
Dec 23, 2023

Conversation

StephanoGeorge
Copy link
Contributor

  • [ x ] Do only one thing
  • [ x ] Non breaking API changes
  • [ x ] Tested

What did this pull request do?

Fixes bug:

Code:

db.InnerJoins("User.Company", db.Select("User__Company.*")).Take(&order)

Expected:

SELECT order.id, order.time, ..., User__Company.id, User__Company.name, User_Company... FROM ...

Actually before:

SELECT order.id, order.time, order... FROM

User Case Description

@jinzhu
Copy link
Member

jinzhu commented Dec 22, 2023

Hi @StephanoGeorge

Could you please add some additional tests to help prevent future breaks? Thank you.

feat: increase readability of code matching table name column name
@StephanoGeorge
Copy link
Contributor Author

@jinzhu Sure, already done, and also made some improvements

@jinzhu jinzhu merged commit 436cca7 into go-gorm:master Dec 23, 2023
34 checks passed
@StephanoGeorge StephanoGeorge deleted the fix-select-star branch December 25, 2023 01:49
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