How to change the value of the integer using views?

Hello. The question seems simple, but I couldn't solve the issue.
There is a model
class Profile(models.Model):
 - - -
 coin = models.IntegerField(default=0)

And through pick up these coins. Thanks in advance!
April 19th 20 at 12:13
1 answer
April 19th 20 at 12:15
What Nada then?
from app_name.models import Profile

profiles = Profile.objects.all()
# get
for profile in profiles:

# assign
profiles = Profile.objects.filter(coin=0)
for profile in profiles:
 profile.coin = 25

Find more questions by tags Django