Partial implementation of add database functionality