Closed vzsg closed 4 years ago
Interesting tidbits:
The test is unfortunately not deterministic. Sometimes the test actually succeeds, sometimes instead of the id
being 10
, the name
field contains "Garfield"
, sometimes both are wrong.
Perhaps I should add a for loop to run it 10 times.
The issue is not a regression caused by postgresql#134. I tested against 1.4.1 and 1.4.0, both showed the symptoms.
A workaround described here https://github.com/vapor/fluent-postgresql/issues/112
This PR at the time of writing is a reproduction of an issue that @rafiki270 reported on Slack.
Notably, if a query uses
join
with another table, this second table's ID field overwrites the values of the first table. This is probably a side-effect of SELECT * and the conflicting column names.Test output currently:
Note that Jon has ID
10
in the result.