look in the authorize.net code on the confirm page to see what is being used for the x_invoice_num value, we usually use the session ID:
$AuthNet_required[$nextIndex] = "x_invoice_num";
$AuthNet_required[$nextIndex] = "".session_id() ."";
If you are using the session ID and having this problem, you should check that the host is properly set up to assign a unique ID for each browsing session.
the transaction will not be stored in the database unless it was successful.