venkish m
17 years ago
emp_master.empno is primary key and emp_hw.empno is foreing key from emp_master
using jsp i inserted a value to emp_hw.empno ( insert into emp_hw values (' ');) a null value for which corresponding parent key in the table emp_master NOT THERE.
so i should get the error thet PARENT KEY NOT FOUND, but the non parent key value is inserted into emp_hw.empno
so this is violating the foreign key constraint.
if i am inserting same quary in sql this query is showing the error , only by using jsp is prob
what can i do
i should get that ereor and non-parent key should not be inserted
is this prob b coz of jsp ?