added a bunch of db mysql wrapper functions
implemented sendMessage