SQL re-integration