• I think it is related to the datatype of the variable. If the columntype is INT the variable must be implicitly converted from the VARCHAR type.

    If the value is always a number, why have you declared it as a VARCHAR and not as an INT?

    ** Don't mistake the ‘stupidity of the crowd’ for the ‘wisdom of the group’! **