changed single and multi functions to search db. created add function to add data to table