better sql interpolation
cleaner error handling for handlers