Fixing MySQL schema