This repo contains a number of extensions for Doctrine 2.1 to be able to use native DB functionality within DQL.
More docs coming soon ;)
As a note, I am still learning about all this stuff. Feel free to use in production, but make sure you lock it to a specific commit! I will be changing this as my knowledge of Doctrine improves =)
e.g. 91 & 15 -> 11
*Usage: BITWISE(FIELD, VALUE, OPERATOR)
The first argument is the field you wish to get the value from, the second is the value on the right side of the binary operation, and the third is the bitwise operation you wish to apply.