I have read here how to do a custom DQL function. But in what file do I put the register function part ? I couldn't find this in the documentation.
I've found it.
You can register it on config.yml
doctrine:
orm:
dql:
numeric_functions:
INT: YourProject\YourBundle\Folder\CastAsInteger