Level-2 / Maphper

Maphper - A php ORM using the Data Mapper pattern
BSD 2-Clause "Simplified" License
52 stars 7 forks source link

Filter to get one value #28

Closed solleer closed 8 years ago

solleer commented 8 years ago

Is there a way to be able to use the filter function to get a single entry without using an id or a for loop.

TRPB commented 8 years ago

This is possible using $mapper->filter(['field' => 'value')->limit(1)->item(0);

solleer commented 8 years ago

Added it to wiki