add the sql stuffs