SQL how to increase or decrease one for a int column in one command

前端 未结 6 2051
长情又很酷
长情又很酷 2020-12-04 09:10

I have an Orders table which has a Quantity column. During check in or check out, we need to update that Quantity column by one. Is there a way to do this in one action or w

6条回答
  •  醉梦人生
    2020-12-04 09:53

    to answer the second:

    make the column unique and catch the exception if it's set to the same value.

提交回复
热议问题