Error
Error Code:
2035
MySQL Error 2035: Mismatched Data Type Submission
Description
MySQL Error 2035 occurs when an application attempts to send a large data value (often called 'long data' or LOB) to a database column that is neither a string nor a binary data type. This usually happens when using prepared statements where the data type bound for a parameter is incompatible with the target column's definition, preventing the server from correctly processing the large input.
Error Message
Can't send long data for non-string/non-binary data types (parameter: %d)
Known Causes
3 known causesIncorrect Parameter Binding Type
The client application is attempting to bind a large value to a parameter in a prepared statement, but it's incorrectly specifying a non-string or non-binary data type for that parameter.
Incompatible Column Definition
The target column in the MySQL database table is defined with a data type (e.g., INT, DATE, BOOLEAN) that cannot store large string or binary data, despite the application attempting to insert such data.
Misuse of Prepared Statement API
The application is using a specific function (like send_long_data) on a parameter that maps to a MySQL column type that is not designed to accept long string or binary data.
Solutions
Coming SoonGeneral Troubleshooting Tips
- Check the error message carefully for specific details
- Review recent changes that might have caused the error
- Search for the exact error code in the official documentation
- Check log files for additional context
- Try restarting the application or service