I have one small doubt in query performance. Basically, I have a table with more than 1C records. sl_id
is the primary key in that table. Currently, I am updating the table column status
to true
(default false
) by using the sl_id
.
In my program, I will have 200 unique sl_id
in an array. I am updating the status
to true
(always) by using each sl_id
.
My doubt:
Shall I use individual update queries by specifing each sl_id
in a where condition to update the status?
(OR)
Shall I use IN
operator and put all 200 unique sl_id
in one single query?
Which one will be faster?