{{theTime}}

Search This Blog

Total Pageviews

java.sql.SQLException: Violation of PRIMARY KEY constraint 'DEPARTMENT_PK'. Cannot insert duplicate key in object 'dbo.DEPARTMENT_TABLE'. The duplicate key value is (100193).

This exception will be thrown when same Department record is inserting into the table DEPARTMENT_TABLE.

Quick Fix1: (Pseudo code)
                 Try {
                             Update department_table
                 }catch(java.sql.SQLException) {
                        Insert into department_table
                 }

No comments:

java.lang.NoSuchFieldError: Class com.sun.tools.javac.tree.JCTree$JCImport

SpringBoot Error: java.lang.NoSuchFieldError: Class com.sun.tools.javac.tree.JCTree$JCImport does not have member field 'com.sun.tools.j...