It looks like the problem is with the query that is on the confirm page when you are storing the details of the order. Based on the error it seems like there might be a problem with the items that were in the order. If the record was not inserted correctly you can get an error like this on the details page because the id would not be present.
Were you getting any errors like this before? You should try doing some more test orders to see if you get this error to occur again. Pay attention to the items that are in the cart, it could be that one of these items has some bad values. Please report back with whatever you discover. Are you seeing the details for the other orders?