|
|
|
|
|
by sgt101
1358 days ago
|
|
I've never bought this : why not user.updateGroups('new@example.com','admin') Sure you have to write the updateGroups method and use SQL to do it, but that's trival. On the otherhand when you want to do something more complex this is when ORM's inject all sorts of subtle and dangerous bugs into your code base. I've had some terrible experiences with them... |
|
For one, you're creating a hard coupling to a specific flavor of SQL. And that's not too mention the fact that you're taking an otherwise purely data object and embedding persistence logic into it - a horrifying abuse of OO.