Inventory saving [MySQL]
#6

Quote:
Originally Posted by Calisthenics
Посмотреть сообщение
2) https://dev.mysql.com/doc/refman/8.0...duplicate.html

Does inventory table have a primary key? If not, set these two (userid, itemid) as PRIMARY KEY. Each player and item is a unique pair and use the syntax I linked above. It either inserts a new row or updates the row if exists.
It's great.Is there anything for example that amount can't be 0?(if it's 0 delete row).I just need it now.
Reply


Messages In This Thread
Inventory saving [MySQL] - by GospodinX - 03.08.2018, 08:50
Re: Inventory saving [MySQL] - by GRiMMREAPER - 03.08.2018, 09:29
Re: Inventory saving [MySQL] - by GospodinX - 03.08.2018, 09:39
Re: Inventory saving [MySQL] - by GRiMMREAPER - 03.08.2018, 09:53
Re: Inventory saving [MySQL] - by Calisthenics - 03.08.2018, 13:10
Re: Inventory saving [MySQL] - by GospodinX - 03.08.2018, 14:47
Re: Inventory saving [MySQL] - by Calisthenics - 03.08.2018, 20:26

Forum Jump:


Users browsing this thread: 1 Guest(s)