How to update android sqlite database database column value to null using ContentValues?

For example, I want to do the following to upgrade a database.

Is there a constant that I can use instead of null that will not compile if I use it like:

 ContentValues args = new ContentValues(); args.put(KEY_RISK_AMOUNT, null); // what constant do I use instead of null? 
+46
android sql database sqlite
Jun 04 2018-11-11T00:
source share
1 answer

Use ContentValues.putNull(java.lang.String) :

 ContentValues args = new ContentValues(); args.putNull(KEY_RISK_AMOUNT); 
+86
Jun 26 2018-11-11T00:
source share



All Articles