Closed ALMMa closed 2 years ago
@ALMMa , I just notice that you started your predicates with MyTypeSelection and then add a predicate of MyType.
Types are more strict now to support self relations and relational properties of the same type of the parent object.
As you have no reference map between both entities it won't find the 2nd predicate data.
Using your example you can add your predicate or create a reference map between the 2 types
Hey @valfrid-ly
Thanks for the reply. So this is intentional, right? It will require a refactor on my end (and maybe others might face the same thing) so it would be nice to have this well documented (sorry if I missed, but didn't see anything regarding this).
But anyway, if that's the actual intention it's just fine.
I'm sorry.
I'm running to finish postgre unit tests and updating docs.
We are behind on that.
Affected version:
1.7.0
(this works with1.6.3
).Consider the table:
Now, consider these two
POCO
entities:And the following class maps:
Mixing predicates from one with the other was never an issue before, as they would rely on the destination table to build the SQL command alias and all.
For instance, this would work before and now it gives back the
multipart identifier ... could not be bound
error:Interesting enough, this only happens on the first execution of a query with both mixed. If you ignore the first execution you fall into another issue from table name/alias mapping and suddenly it works.
Though I'm not sure on how much this could impact the community, this can lead to previously shared code infrastructure being rendered useless and upgrading would require a refactor to make explicit chained calls to always have the same
POCO
types on predicates.Please be advised.