ORA-12704 character set mismatch

I got “ORA-12704 character set mismatch ”  error in Oracle database.

 

ORA-12704 character set mismatch

 

Details of error are as follows.

ORA-12704 character set mismatch

Cause: One of the following:
  •  The string operands (other than an NLSPARAMS argument) to an operator or built-in function do not have the same character set.
  • An NLSPARAMS operand is not in the database character set.
  • String data with character set other than the database character set is passed to a built-in function not expecting it.
  • The second argument to CHR() or CSCONVERT() is not CHAR_CS or NCHAR_CS.
  • A string expression in the VALUES clause of an INSERT statement, or the SET clause of an UPDATE statement, does not have the same character set as the column into which the value would be inserted.
  • A value provided in a DEFAULT clause when creating a table does not have the same character set as declared for the column.
  • An argument to a PL/SQL function does not conform to the character set requirements of the corresponding parameter.
Action: Strings declared with NCHAR or NCHAR VARYING do not interoperate with strings declared with CHAR or VARCHAR2. Use TRANSLATE() function to explicitly convert one to the other.

 

 

character set mismatch

This ORA-12704 errors are related with the One of the following:

  •  The string operands (other than an NLSPARAMS argument) to an operator or built-in function do not have the same character set.

  • An NLSPARAMS operand is not in the database character set.

  • String data with character set other than the database character set is passed to a built-in function not expecting it.

  • The second argument to CHR() or CSCONVERT() is not CHAR_CS or NCHAR_CS.

  • A string expression in the VALUES clause of an INSERT statement, or the SET clause of an UPDATE statement, does not have the same character set as the column into which the value would be inserted.

  • A value provided in a DEFAULT clause when creating a table does not have the same character set as declared for the column.

  • An argument to a PL/SQL function does not conform to the character set requirements of the corresponding parameter.

 

 

To solve this error, Strings declared with NCHAR or NCHAR VARYING do not interoperate with strings declared with CHAR or VARCHAR2. Use TRANSLATE() function to explicitly convert one to the other.

 

You can use the conversion function ( NCHAR, VARCHAR2  ) to change the type of the two columns to be consistent.

 

You can use to_char Function to do character conversion between nvarchar2 to varchar2

You can use to_nchar to do character conversion between varchar2 to nvarchar2.

You can use cast Function to do character conversion between varchar2 to nvarchar2

You can use translate…using Function converts varchar2 to nvarchar2

 

Do you want to learn Oracle Database for Beginners, then read the following articles.

Oracle Tutorial | Oracle Database Tutorials for Beginners ( Junior Oracle DBA )

 

About Mehmet Salih Deveci

I am Founder of SysDBASoft IT and IT Tutorial and Certified Expert about Oracle & SQL Server database, Goldengate, Exadata Machine, Oracle Database Appliance administrator with 10+years experience.I have OCA, OCP, OCE RAC Expert Certificates I have worked 100+ Banking, Insurance, Finance, Telco and etc. clients as a Consultant, Insource or Outsource.I have done 200+ Operations in this clients such as Exadata Installation & PoC & Migration & Upgrade, Oracle & SQL Server Database Upgrade, Oracle RAC Installation, SQL Server AlwaysOn Installation, Database Migration, Disaster Recovery, Backup Restore, Performance Tuning, Periodic Healthchecks.I have done 2000+ Table replication with Goldengate or SQL Server Replication tool for DWH Databases in many clients.If you need Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS Consultancy and Training you can send my email adress [email protected].-                                                                                                                                                                                                                                                 -Oracle DBA, SQL Server DBA, APPS DBA,  Exadata, Goldengate, EBS ve linux Danışmanlık ve Eğitim için  [email protected] a mail atabilirsiniz.

Leave a Reply

Your email address will not be published. Required fields are marked *