Added missing primary key condition part