MySQL model with PARTITION

Hi. I'm looking for a solution to set custom partition with MySQL models in Phalcon. I tried to figure it out with modelsManager, behaviours, events etc., but still can not find a solution. What I'm looking for:

<?php

$model = new SomeThing;
$model->setPartition('p1');
$model->find(...);

// or

$model->find(['partition' => 'p1']); // with conditions

And the output should be:

SELECT `id`, `name` FROM `something` PARTITION (`p1`);

Thanks in advance.

Afaik PHQL doesn't support partitions... you'd have to rewrite the PHQL parser logic for it to work.

You should submit a NFR on github