I need a procedure for delete multiple rows in multiple tables by passing array set of values in parameters
Consider 3 tables:
student_master(id,student_name);
subject_master(id,subject_name);
marks(id,student_id,student_id,subject_id,marks)
here in parameter for e.g student id will be: a['1','3','7','15']
What is the procedure for this criteria?
If your student_id
s are integer or bigint then use without quote:
delete from marks
where student_id = ANY(Array [1,3,7,15])
returning student_id
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With