سؤال

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