Fix incorrect sql service usage
Apply code review
Merge pull request #1014 from andrerod/dev

Fix incorrect sql service usage