• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

MYSQL Add vip days from a table to another one

MxSoft

Leave Tibia, Live Life.
Joined
Dec 22, 2009
Messages
1,804
Solutions
1
Reaction score
43
Location
Mexico
Hi i merged my servers databases and one of my servers have the vip days in "premiumdays" and i need to add the vip days to table "vipdays".
 
Just run that query:

Code:
UPDATE accounts SET vipdays = acc.premiumdays FROM accounts, accounts acc WHERE accounts.vipdays = acc.premiumdays;
 
#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM accounts, accounts WHERE accounts.vipdays = acc.premiumdays' at line 1
 
field is a column value of a single row, columns are single fields of all rows.

he wanted the query to execute for all rows and columns premiumdays & vipdays, how is that a field?
 
Back
Top