Only for first time update data on mysql server .when second time click botton it’s can’t update data .
And when close screen and open again then it work for 1st click .but i Went to update data several time without reopen screen .anyone help me?
You aren’t increasing global count…
If global count is 1 then when you click button then it update 2 on database and the global count is still 1 then you press the button again and the value to be updated will be 2 again…
Everytime you update data increase the value of global count