T_TRADE now writes it to the db for real.
Fixed the errors, now the real testing can begin.