I've found a problem that I can't quite wrap my head around.

I have a combobox which I have linked to a lookup table in a SQL database. Essentially, the lookup table has a list of user names in one column and a matching column with their initials. The combobox is bound to display the full username column, but the value is actually pointed at the initials column.

The chosen value from this combobox will fill another table (TableX).

Now, if I go into an edit mode to edit one of the fields in TableX and simply don't change anything and confirm the edits, there is no problem.
However, if I change ANY of the fields, an exception will be thrown explaining that the value from the user combobox is too long for the table field.

If I display a messagebox to see what the value is that is chosen before updating the table, I will see that the value is OK and of appropriate type and length for the table.

The other kicker is that if I simply bind the combobox to the same display and value (both set to initials), the code works perfectly. I can change and modify any value and there are no problems updating the table.

Why does the code work when the combobox binding is set to display and use the same value, but it does not work when it is set to display one column but give value to another?

Terry Welch