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
CREATETABLEIF NOT EXISTS Parent (
id INTEGER IDENTITY PRIMARY KEY,
name VARCHAR(100),
nested_child_id NUMERIC,
nested_type VARCHAR(100)
);
CREATETABLEIF NOT EXISTS Child (
id INTEGER IDENTITY PRIMARY KEY,
name VARCHAR(100)
);
A simple loading of parent will generate the issue (the save is ok) :
varparent = repository.findById(1L)//failed because sql query is not correct the embedded prefix is missing: "PARENT"."CHILD_ID" must be "PARENT"."NESTED_CHILD_ID"
SQL generated : SELECT "PARENT"."ID" AS "ID", "PARENT"."NAME" AS "NAME", "PARENT"."NESTED_TYPE" AS "NESTED_TYPE", "PARENT"."CHILD_ID" AS "CHILD_ID" FROM "PARENT" WHERE "PARENT"."ID" = ?
mp911de
changed the title
SQL column name resolution failed for Embedded with AggregateReference
SQL column name resolution failed for embeddable with AggregateReferenceDec 14, 2023
The sql query is not generate with the right column name for embedded AggregateReference property. The embedded prefix definition is not set.
Example :
A simple loading of parent will generate the issue (the save is ok) :
SQL generated : SELECT "PARENT"."ID" AS "ID", "PARENT"."NAME" AS "NAME", "PARENT"."NESTED_TYPE" AS "NESTED_TYPE", "PARENT"."CHILD_ID" AS "CHILD_ID" FROM "PARENT" WHERE "PARENT"."ID" = ?
Here project to reproduce error : Test project
The text was updated successfully, but these errors were encountered: