Why do you want to change your ids? The id column on a table should never be changed. This should uniquely identify a row. If you want to change it for sorting, you should find another way to sort your table, like by name.
When you create a unique id field for a table this field should only be used by the database for key purposes. It shouldn't be something that can be changed.
Other than that if the field is unique, and controlled by the database (i.e auto_increment in MySQL) then you will need to move one record to an unused id, and then move the second record to the first records id, and finally move the original record back to the second records id.
update comics set id = 100
where id = 2;
update comics set id = 2
where id = 5;
update comics set id = 5
where id = 100;