when i insert employee data this error occur
sub-query return more than 1 value this is not permitted when the subquery follows = , >=,>,<,<=
What I have tried:
insert INTO Transaction_Employee(Memployee_id,Emp_bio_id,des_id,Department_id,Unit_id,etype_id,payment_id,Leave_id,joining_date,resign_date,leave_start_date,Bank_id)
Values
(
@memployee,@emp_bio_id,(select distinct des_id From Setup_designation where des_name=@desig),(select distinct Department_id from Setup_Department where Depart_name=@deprt),
(select distinct Unit_id from Setup_Unit where unit_name=@unit),(select distinct etype_id from Setup_Enployeetype where ename=@emp_type),
(select distinct payment_id from Setup_Payment_Type where payment_name=@payment),(select distinct Leave_id from Setup_Leave where leave_name=@leavename),
@joining_date,@resign_date,@leave_startdate,(select distinct Bank_id from Setup_Bank where bank_name=@bank_name)
)