I know how to do this, but i think I\'ll overcomplicate it with double selects and so on.
How can you do this (example in pseudo-sql)
UPDATE some_table S
In this case, you could use an XOR type operation:
UPDATE some_table SET an_int_value = an_int_value XOR 1
This is assuming that an_int_value will always be 1 or 0 though.