• 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!

Jak dodać tabele "Bans" w MYSQL?

Status
Not open for further replies.

Czaku

Banned User
Joined
Mar 24, 2010
Messages
177
Reaction score
1
Yo,
Jakie polecenie MYSQL odpowiada za dodanie tabeli bans? :peace:
 
Lua:
CREATE TABLE `bans`
(
	`id` INT UNSIGNED NOT NULL auto_increment,
	`type` TINYINT(1) NOT NULL COMMENT '1 - ip banishment, 2 - namelock, 3 - account banishment, 4 - notation, 5 - deletion',
	`value` INT UNSIGNED NOT NULL COMMENT 'ip address (integer), player guid or account number',
	`param` INT UNSIGNED NOT NULL DEFAULT 4294967295 COMMENT 'used only for ip banishment mask (integer)',
	`active` TINYINT(1) NOT NULL DEFAULT TRUE,
	`expires` INT NOT NULL,
	`added` INT UNSIGNED NOT NULL,
	`admin_id` INT UNSIGNED NOT NULL DEFAULT 0,
	`comment` TEXT NOT NULL,
	`reason` INT UNSIGNED NOT NULL DEFAULT 0,
	`action` INT UNSIGNED NOT NULL DEFAULT 0,
	`statement` VARCHAR(255) NOT NULL DEFAULT '',
	PRIMARY KEY (`id`),
	KEY `type` (`type`, `value`),
	KEY `active` (`active`)
) ENGINE = InnoDB;
 
Nie wyłączaj :p
Po prostu wklej to zapytanie i będzie dobrze =D
 
#1005 - Can't create table 'xx_war.bans' (errno: 121)


;// ?
 
Nie może stworzyć tabeli 'xx_war.bans'.
Nie znam się na tym, może ktoś zaraz napisze Ci jak to naprawić.
 
CREATE TABLE `bans`
(
`id` INT UNSIGNED NOT NULL auto_increment,
`type` TINYINT(1) NOT NULL COMMENT '2 - ip banishment, 1 - namelock, 2 - account banishment, 2 - notation, 4 - deletion',
`value` INT UNSIGNED NOT NULL COMMENT 'ip address (integer), player guid or account number',
`param` INT UNSIGNED NOT NULL DEFAULT 4394927245 COMMENT 'used only for ip banishment mask (integer)',
`active` TINYINT(1) NOT NULL DEFAULT TRUE,
`expires` INT NOT NULL,
`added` INT UNSIGNED NOT NULL,
`admin_id` INT UNSIGNED NOT NULL DEFAULT 0,
`comment` TEXT NOT NULL,
`reason` INT UNSIGNED NOT NULL DEFAULT 0,
`action` INT UNSIGNED NOT NULL DEFAULT 0,
`statement` VARCHAR(255) NOT NULL DEFAULT '',
PRIMARY KEY (`id`),
KEY `type` (`type`, `value`),
KEY `active` (`active`)
) ENGINE = InnoDB;

ja mam tak ;<
 
Dobra chodzi o to że na swoim pc dodaje lajtowo tą tabelke i nawet bym niepisał ale na moim pro dedyku jest problem
#1005 - Can't create table 'Czaku_war.bans' (errno: 121)
Gdzie Czaku_war to nazwa bazy :O
o nazwie ban mogę dodać a bans już nie, tabelka bans jest skasowana więc ja nie widze problemu :O
 
Komuś przedtem chodziło o to że:

'xx_war.bans'

Zamiast 'xx_war.bans' ma być 'xx_war-bans' .

Ale pewnie to nie pomoże.
 
też mam ten problem, próbuje kodu Sep~

to mi piszE:

Code:
#1067 - Invalid default value for 'param'


ja tej kropki nigdzie nie wpisuje, xx_war (przynajmniej u mnie) to nazwa bazy, a bans to nazwa tabeli ktora chce dodac.


edit:
coś wyczytałem na necie że chodzi o Indexy.. wtf?:p
 
Czaku, masz wszystko w Xamppie?

Tzn. plik bans.php ?

A w index.php powinno być coś takiego:

case "bans":
$topic = "Zbanowani";
$subtopic = "bans";
include("bans.php");
break;

Wydaję mi się że nie o to Ci chodziło :blink:
 
Ej, jak chcę żeby wszystkie rzeczy które miały trafiac do tabeli bans, żeby trafiały do tabeli "ban" to w indexie trzeba to zmienić na ban zamiast bans wszystko ? :>
 
Status
Not open for further replies.
Back
Top