Interviews2 answers
Can we Perform DML operations using joins only
2 Answers
we can use
Shashidhar RPosted Oct 26, 2024, 5:33 AM EDT
Did you mean Only Joins ?
--Update using Join
update c
set c.Fee=1000
from [t_Course] c join [t_Mapping] m
on c.course_name=m.course_name
where m.stud_id=1
-- Delete using join
delete s
from [t_Student] s join [t_Mapping] m
on s.id=m.stud_id
where m.stud_id=3
Rahul BoratePosted Mar 15, 2018, 2:37 AM EDT