change the sql generator