"UPDATE " + DatabaseFıelds.TABLE_NAME + " SET " + DatabaseFıelds.SUBJECT_PROGRESS + " = " + point + " WHERE " + DatabaseFıelds.SUBJECT_ID + " = " + id;
"UPDATE " + DatabaseFıelds.TABLE_NAME +
" SET " + DatabaseFıelds.SUBJECT_PROGRESS + " = " +
point + " WHERE " + DatabaseFıelds.SUBJECT_ID + " = " + id;
这个查询更新了我的值,但是我希望它添加到现有的值中。如何解决此问题?
lndjwyie1#
我猜你想把point的值加到DatabaseFıelds.SUBJECT_PROGRESS的现有值上,对吗?你可以这样做:
point
DatabaseFıelds.SUBJECT_PROGRESS
"UPDATE " + DatabaseFıelds.TABLE_NAME + " SET " + DatabaseFıelds.SUBJECT_PROGRESS + " = " + DatabaseFıelds.SUBJECT_PROGRESS + " + " + point + " WHERE " + DatabaseFıelds.SUBJECT_ID + " = " + id;
DatabaseFıelds.SUBJECT_PROGRESS + " + " + point +
" WHERE " + DatabaseFıelds.SUBJECT_ID + " = " + id;
1条答案
按热度按时间lndjwyie1#
我猜你想把
point
的值加到DatabaseFıelds.SUBJECT_PROGRESS
的现有值上,对吗?你可以这样做: