Database class edit

Added select and insert function.