Put result of primary_key() method into a variable

This avoid the notice : "Only variables should be passed by reference" that could appear here.
Merge pull request #105 from Foine/patch-7

Put result of primary_key() method into a variable