On the confirm.php page, the store order summary behavior is set to store the Session ID into a column in your database. The data type in the store order summary is set to numeric.
Double click the store order summary server behavior on the confirm, page. Find the column that the Session ID is being stored in and make sure the data type is set to text, then click ok.
you may also need to check in the Store Order Details table if the session ID is being stored in a column in the order details table.