A Static-Based Approach to Detect SQL Semantic Bugs