trying to fix db errors
began work on trades