Error 2402

Severity

16

Message text

Error converting client characters into server's character set. Some character(s) could not be converted.

Explanation

This error occurs during insertion of data (insert or bcp) when Adaptive Server fails to convert a character to the required character set.

Error 2402 usually occurs when:

This error occurs during normal processing and it prevents query execution.

Action

The following options are available for recovering from error 2402.


Changing the data

Modify the incoming data so that it contains characters recognizable by Adaptive Server.


Turning off character set conversion

If the error occurs while you are using isql, bcp, or defncopy, you can use the -J (UNIX and Windows) command-line option with no character set name to set the client's character set to NULL. If you use this command-line option without specifying a character set name, no conversion takes place and no error message is sent. As a result, some characters sent by the client to the Adaptive Server may not be interpreted correctly by the Adaptive Server and vice versa. (If only 7-bit characters are being handled, no incorrect interpretation will take place.)

Otherwise, you can turn off conversion so that characters are sent and received unchanged with the following command:

1> set char_convert off
2> go

Turning off character set conversion error reporting

You can turn off the printing of error messages with the following command:

1> set char_convert on with no_error
2> go

Bytes that cannot be converted are replaced with an ASCII question mark (“?”).

NoteThe preceeding commands turn off error reporting only when characters are being sent from Adaptive Server to the client. Error 2402 is still raised if a client sends a character that Adaptive Server cannot convert.

Additional information

Refer to “Character set conversion in Adaptive Server” in chapter 10 of the System Administration Guide: Volume 1 for details about character set conversion.

Versions in which this error is raised

All versions