test code for sqlalchemy