Assuming I have such table
|---------------------|------------------|
| ID | Name |
|---------------------|------------------|
| 1 | x |
|---------------------|------------------|
| .. | x |
|---------------------|------------------|
| N | x |
|---------------------|------------------|
I need to change name fields to "z" for IDs between 30 and 100. Is there any way to use a loop or a while condition instead of doing this:
UPDATE table
SET Name = 'z'
WHERE ID = 30
OR ID = 31
OR ID = 32
...