squash this commit
refactoring sql