Open halcwb opened 3 years ago
Just a quick look into this one, it seems that something in this.ReadEntities
goes wrong:
SELECT [p].[MYCOLUMN_ID] as '[p].[MYCOLUMN_ID]' ...
, it probably leaves the alias p as how would the SQL know which table is it used for (as multiple tables can have same name columns)e.SetColumnSilent(reader.GetName(i),value)
sets a correct value, but GetName(0) returns the full [p].[MYCOLUMN_ID]
MYCOLUMN_ID
which is not in that dictionary, because it has the full alias and not the column-name only.@Thorium So, is this something you can reproduce? Or do you need the generated SQL output?
Describe the bug When using composed queries an unexpected behavior occurs when a join is involved in a query. This results in a select with wrong values. See code examples below.
To Reproduce
Expected behavior Clearly the second query result is inconsistent with the other queries.
Desktop (please complete the following information): .NET SDK (reflecting any global.json): Version: 5.0.202 Commit: db7cc87d51
Runtime Environment: OS Name: Windows OS Version: 10.0.17763 OS Platform: Windows RID: win10-x64 Base Path: C:\Program Files\dotnet\sdk\5.0.202\
Host (useful for support): Version: 5.0.5 Commit: 2f740adc14
.NET SDKs installed: 5.0.200-preview.21077.7 [C:\Program Files\dotnet\sdk] 5.0.201 [C:\Program Files\dotnet\sdk] 5.0.202 [C:\Program Files\dotnet\sdk]