While trying to update a foreign key value of my table 2, I get below error and how to update a foreign key value using criteria queries.
User Entity class: