SQLite let's us define our own functions (we do this for datetime stuff) any reason not to do that here as well?