You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If we have something like
class Base (SINGLE_TABLE, with DISCRIMINATOR)
class Sub extends Base (SUPERCLASS_TABLE)
and we have a query like
SELECT b FROM Base b WHERE (TREAT(b) AS Sub).someField = value
then this currently ignore the TREAT (cast) whereas it should add a DISCRIMINATOR clause.
The problem is that we can only add the discriminator clause to a BooleanExpression ... i.e let it propagate back up to the
{...}.someField = value
and add the discriminator constraint there.
The text was updated successfully, but these errors were encountered:
See ObjectExpression.cast(). Near the end there is a block "if (castSqlTbl == table)". We need to allow ObjectExpression to have a BooleanExpression adding (when part of FILTER), and then when we evaluate a BooleanExpression from the ObjectExpression (e.g in ObjectExpression = value) we then add the BooleanExpression the ObjectExpression has attached.
then this currently ignore the TREAT (cast) whereas it should add a DISCRIMINATOR clause.
By not adding a discriminator clause to the query it could result in the RDBMS having to iterate through a lot more records in any given table - possibly making the query much slower.
If we have something like
class Base (SINGLE_TABLE, with DISCRIMINATOR)
class Sub extends Base (SUPERCLASS_TABLE)
and we have a query like
SELECT b FROM Base b WHERE (TREAT(b) AS Sub).someField = value
then this currently ignore the TREAT (cast) whereas it should add a DISCRIMINATOR clause.
The problem is that we can only add the discriminator clause to a BooleanExpression ... i.e let it propagate back up to the
{...}.someField = value
and add the discriminator constraint there.
The text was updated successfully, but these errors were encountered: