Data mismatch

Design by Sue

Registered User.
Local time
Today, 02:58
Joined
Jul 16, 2010
Messages
809
My table has a field that is a number (long integer) and I am trying to update the field from a form. On the form I have my text box set as Format:General Number. What I am missing here because I get an error message 3464 Data Mismatch? What should have the form control set to to clear this message. (sorry if my terminology is incorrect - been a long time since working on this)

Thanks!

EDIT I also tried leaving format on the form blank and still the same problem.
 
Data Mismatch usually means you have put in data not consistent with the data type. So my first question is, did you try to enter data with a decimal point or decimal fraction? Because you can't do that for LONG INTEGER numbers.
 
Adding to TheDocMan: just this morning I got this same error, and the problem was my field was a Long Integer, and the value was greater than the max long integer of 2 billion and change. I could have changed it to Big Integer, but in this case chose a Short Text data type.

BTW, what you set the Format to is irrelevant: that is for DISPLAY purposes, not for STORAGE purposes.
 
Adding to TheDocMan: just this morning I got this same error, and the problem was my field was a Long Integer, and the value was greater than the max long integer of 2 billion and change. I could have changed it to Big Integer, but in this case chose a Short Text data type.

BTW, what you set the Format to is irrelevant: that is for DISPLAY purposes, not for STORAGE purposes.
The value us only 40 so I doubt that is the problem... thanks for the explanation of display purposes vs storage!
 
Data Mismatch usually means you have put in data not consistent with the data type. So my first question is, did you try to enter data with a decimal point or decimal fraction? Because you can't do that for LONG INTEGER numbers.
I am not on the system right now but will check this to be sure - I think decimal is left blank..but I could be wrong
 
General number isn't right. That would accept 13.2 for instance, but if you are storing the value in a long data type field you will get a type mismatch somewhere. You need to prevent the control receiving anything other than a whole number.
 
I think decimal is left blank..but I could be wrong

I specifically intended that question to see if what you tried to enter contained an explicit decimal point. This could also occur if you had a negative scaling factor, which would move the implicit decimal point to the left. You didn't mention this, but is there event code associated with the control you are using to enter the misbehaving number? If so, what is it? I'm asking what might sound like oddball, off-the-wall questions to try to determine what could do this to you. A plain vanilla text box with no event code and bound to a long integer field is a commonly used setup. For it to act so badly, SOMETHING is making this not behave so well. The only other explanation MIGHT be corruption, for which a compact & repair operation would help. But right now, it is straw-grasping time.
 
From memory putting 1.2 into an integer field simply drops the decimal, so I doubt that is the cause.
 

Users who are viewing this thread

Back
Top Bottom