Insert as a transaction