set primary_key to default(id) when primary_key at the table is not set.

set primary_key to default(id) when primary_key at the table is not set.