Transactions almost working