Hello experts I need to update next column value with divisible by 100I need to update value Of B column in C column as shown in figure in postgresql

有帮助吗?

解决方案

You can use the Modulo operator, something along these lines:

UPDATE YourTable
SET NewBalance = Balance - (Balance % 100);

HTH

许可以下: CC-BY-SA归因
不隶属于 dba.stackexchange
scroll top