cleaner sql code