Added validation for primary key property