implemented simpledb