I didn't give it a thought on porting it, but via a quick checks mysql/oracle/posgres/sqlite are covered, albeit mysql is the only one that returns the length in bytes, not characters.