Fixed txnId - now uses random()