I solved my problem placing the insertable=false, updatable=false in the @JoinColumn annotation in both classes, Person and Company.
I solved my problem placing the insertable=false, updatable=false in the @JoinColumn annotation in both classes, Person and Company.