Transaction logic implementation