j4mie / idiorm

A lightweight nearly-zero-configuration object-relational mapper and fluent query builder for PHP5.
http://j4mie.github.com/idiormandparis/
2.01k stars 369 forks source link

Hello, a problem when primary key is not 'id'. #333

Closed xtlsoft closed 6 years ago

xtlsoft commented 6 years ago

I am now facing a problem. The Primary Key in my table is 'pid' instead of 'id', and I don't have an 'id' key. So I failed in writing data to that table. This is the error message I got: image Can you fix this problem? Thank you.

treffynnon commented 6 years ago

http://idiorm.readthedocs.io/en/latest/configuration.html#id-column