added ability to get from database and append to table