It is necessary to update all records in the table with a step 5.

  • Need to update every 5 line. - Vlad
  • and what is the question, what does every 5 mean, to take into account that there is no order as such. How this is supposed to be done (SQL - query, stored procedure, language extension, cursors). In general, try to ask questions deployed. - pavel
  • There are 1000 entries, I need a sql query to update a specific cell, with an id, which in the loop increases by 5. - Vlad
  • Update table set [bla-bla-bla] where (id % 5 = 0) so what? - pavel
  • It is desirable that it was a cyclical request? Can I do this? Type: for (int i = 1; i <1000; i + = 5) {} - Vlad

1 answer 1

 update table set [bla-bla-bla] where (id % 5 = 0)