This Query is Work : use for insert
INSERT INTO Employee VALUES(@EmployeeID,@EmployeeName,@Emp_Title,@Address_1, @Address_2,@Area, case when @City<=0 then null else @City end,
@Postcode,@JoiningDate,@BirthDate,@LeavingDate,case when @DepartmentID <=0 then null else @DepartmentID end, case when @DesignationID<=0 then null else @DesignationID end, @MobileNo,@Office_PhoneNo,@Residence_PhoneNo,@Email_ID,@Active);
i also want to use
case here but not Works
Update Employee Set EmployeeName=@EmployeeName,Emp_Title=@Emp_Title,Address_1=@Address_1,Address_2=@Address_2,Area=@Area,City=@City,Postcode=@Postcode,JoiningDate=@JoiningDate,BirthDate=@BirthDate,LeavingDate=@LeavingDate,DepartmentID=@DepartmentID,DesignationID=@DesignationID,MobileNo=@MobileNo,Office_PhoneNo=@Office_PhoneNo,Residence_PhoneNo=@Residence_PhoneNo,Email_ID=@Email_ID,Active=@Active WHERE EmployeeID = @EmployeeID
any one help me to out This...!!