HELP MYSQL ERROR Please
#4

In table structure, you can alter the table and modify the column to add a default value (within web app). Or you can execute this query once:
pawn Code:
ALTER TABLE `ucty3` CHANGE `Armour` `Armour` float NOT NULL DEFAULT '0.0' AFTER `Skin`;
It is advised to edit the CREATE TABLE too in case you need to import the table in the future:
pawn Code:
`Armour` float NOT NULL DEFAULT '0.0',
What I also noticed is that you have columns WSlot0 to WSlot11. This is against 1NF (repeating groups). Create a separate table.

Another thing is this:
pawn Code:
`Box` tinyint(1) NOT NULL,
 `Kungfu` tinyint(1) NOT NULL,
 `Kneehead` tinyint(1) NOT NULL,
 `Grabkick` tinyint(1) NOT NULL,
 `Elbow` tinyint(1) NOT NULL,
Instead of 5 columns that 4 of them are 0, have a single column name fighting_style and set a value between 0 and 4. You can easily find out which fighting style the player has.
Reply


Messages In This Thread
HELP MYSQL ERROR Please - by itachi - 03.12.2019, 16:03
Re: HELP MYSQL ERROR Please - by Joe Staff - 03.12.2019, 16:33
Re: HELP MYSQL ERROR Please - by itachi - 03.12.2019, 16:39
Re: HELP MYSQL ERROR Please - by Calisthenics - 03.12.2019, 18:24

Forum Jump:


Users browsing this thread: 1 Guest(s)