How do I delete rows from a database using entity framework.
For example, I could use the following query today:
Code:
But I was trying to use the entity framework, but doesn't seem like delete is an option?
Code:
Thank you!
Читать далее...
For example, I could use the following query today:
Code:
$db->query('DELETE FROM mytable WHERE timestamp > ?', [$timestamp]);
But I was trying to use the entity framework, but doesn't seem like delete is an option?
Code:
\XF::finder('myaddon:myentity')->where('timestamp', '>', $timestamp)->delete();
Thank you!
Читать далее...