I would like to run an update on SQL, and set each key (category_id) to the value (category_order). Basically an arrayed version of the following:
SET category_order = $value
WHERE category_id = $key
Yes, I know I could run a foreach loop, and update each individually, but that would add 5 queries, and possibly more as I add more categories. I like to do things as efficiently as possible. Now if the keys and values were in their own arrays ($keys and $values, respectively), would it be possible to run this update code using the arrays?