• 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 Database Issue

wildcatk23

New Member
Joined
Jan 6, 2012
Messages
48
Reaction score
0
IM getting this error in my server when someone logs on.


mysql_real_query(): INSERT INTO `killers` (`death_id`, `final_hit`, `unjustified`, `war`) VALUES (1, 1, 0, 0) - MYSQL ERROR: Unknown column 'war' in 'field list' (1054)
 
Last edited:
I fixed that one, Now im getting this one when someone dies.




mysql_real_query(): INSERT INTO `killers` (`death_id`, `final_hit`, `unjustified`, `war`) VALUES (1, 1, 0, 0) - MYSQL ERROR: Unknown column 'war' in 'field list' (1054)

mysql_real_query(): INSERT INTO `lottery` (`name`, `item`) VALUES ('Booga', 'mastermind shield'); - MYSQL ERROR: Table 'otland.lottery' doesn't exist (1146)
 
Last edited:
^ Fixed Thank you,

You being very helpful lol..


What about this one

mysql_real_query(): SELECT `id`, `guild_id`, `enemy_id` FROM `guild_wars` WHERE `status` IN (1,4) AND `end` > 0 AND `end` < 1326833312 - MYSQL ERROR: Table 'otland.guild_wars' doesn't exist (1146)
 
You go to PhpMyAdmin and choose your database, then you press SQL and write the code that I gave you ;)
Code:
CREATE TABLE `guild_wars` (
	`id` INT UNSIGNED NOT NULL AUTO_INCREMENT,
	`guild_id` INT UNSIGNED NOT NULL COMMENT 'the guild which declared the war',
	`enemy_id` INT UNSIGNED NOT NULL COMMENT 'the enemy guild at war',

	`frag_limit` INT UNSIGNED NOT NULL DEFAULT 10 COMMENT 'kills needed to win the war',
	`declaration_date` INT UNSIGNED NOT NULL,
	`end_date` INT UNSIGNED NOT NULL,
	`guild_fee` INT UNSIGNED NOT NULL DEFAULT 1000 COMMENT 'amount of money the guild has to pay if loses the war',
	`enemy_fee` INT UNSIGNED NOT NULL DEFAULT 1000 COMMENT 'amount of money the enemy guild has to pay if loses the war',
	`guild_frags` INT UNSIGNED NOT NULL DEFAULT 0,
	`enemy_frags` INT UNSIGNED NOT NULL DEFAULT 0,
	`comment` VARCHAR(255) NOT NULL DEFAULT '' COMMENT 'the guild leader can leave a message for the other guild',
	`status` INT NOT NULL DEFAULT 0 COMMENT '-1 -> will be ignored (finished or unaccepted) 0 -> to be started 1 -> started/not finished',

	PRIMARY KEY (`id`),
	FOREIGN KEY (`guild_id`) REFERENCES `guilds` (`id`) ON DELETE CASCADE,
	FOREIGN KEY (`opponent_id`) REFERENCES `guilds` (`id`) ON DELETE CASCADE
try this, tell me if it is something wrong with it
 
#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 '' at line 18

Im using 0.3.6pl
 
Back
Top