Файл: install/db_tables/sql.sql
Строк: 41
CREATE TABLE `gorod_conf` (
`open` VARCHAR( 2 ) NOT NULL,
`kopi` INT NOT
NULL ,
`kopi_v` VARCHAR( 32 ) NOT NULL ,
`kopi_k` VARCHAR( 32 ) NOT NULL
,
`kopi_time` INT NOT NULL ,
`luna` INT NOT NULL
);
CREATE TABLE
`gorod_bazar` (
`id` INT NOT NULL AUTO_INCREMENT ,
`name` VARCHAR( 150 )
NOT NULL ,
`price` INT NOT NULL ,
`life` INT NOT NULL ,
PRIMARY KEY (
`id` )
);
CREATE TABLE `gorod_band` (
`id` INT NOT NULL
AUTO_INCREMENT ,
`name` VARCHAR( 50 ) NOT NULL ,
`glava` VARCHAR( 32 )
NOT NULL ,
`zarplata` INT NOT NULL ,
`bal` INT NOT NULL ,
`kill` INT NOT
NULL ,
`balans` INT NOT NULL ,
`opis` VARCHAR( 250 ) NOT NULL ,
`open`
VARCHAR( 3 ) NOT NULL ,
`needbal` INT NOT NULL ,
`krishaopen` VARCHAR( 3
) NOT NULL ,
`price` INT NOT NULL ,
`krishaprice` INT NOT NULL
,
`strana` VARCHAR( 5 ) NOT NULL ,
PRIMARY KEY ( `id` )
);
CREATE
TABLE `gorod_bar` (
`id` INT NOT NULL AUTO_INCREMENT ,
`name` VARCHAR( 50
) NOT NULL ,
`price` INT NOT NULL ,
`life` SMALLINT NOT NULL ,
PRIMARY
KEY ( `id` )
);
CREATE TABLE `gorod_mobi` (
`id` INT NOT NULL
AUTO_INCREMENT ,
`name` VARCHAR( 50 ) NOT NULL ,
`path` VARCHAR( 15 ) NOT
NULL ,
`price` INT NOT NULL ,
PRIMARY KEY ( `id` )
);
CREATE TABLE
`gorod_firm` (
`id` INT NOT NULL AUTO_INCREMENT ,
`name` VARCHAR( 50 )
NOT NULL ,
`opis` VARCHAR( 250 ) NOT NULL ,
`lasttake` BIGINT NOT NULL
,
`dohod` INT NOT NULL ,
`balans` INT NOT NULL ,
`user` VARCHAR( 32 )
NOT NULL ,
`date` BIGINT NOT NULL ,
`update` BIGINT NOT NULL ,
`pritok`
INT NOT NULL,
`birga` VARCHAR( 3 ) NOT NULL,
PRIMARY KEY ( `id` )
);
CREATE TABLE `gorod_tur` (
`id` INT NOT NULL AUTO_INCREMENT
,
`name` VARCHAR( 50 ) NOT NULL ,
`opis` VARCHAR( 250 ) NOT NULL
,
`price` INT NOT NULL ,
`path` VARCHAR( 15 ) NOT NULL ,
PRIMARY KEY (
`id` )
);
CREATE TABLE `gorod_dom` (
`id` INT NOT NULL AUTO_INCREMENT
,
`name` VARCHAR( 50 ) NOT NULL ,
`path` VARCHAR( 15 ) NOT NULL
,
`price` INT NOT NULL ,
PRIMARY KEY ( `id` )
);
CREATE TABLE
`gorod_avto` (
`id` INT NOT NULL AUTO_INCREMENT ,
`name` VARCHAR( 50 )
NOT NULL ,
`path` VARCHAR( 15 ) NOT NULL ,
`price` INT NOT NULL
,
PRIMARY KEY ( `id` )
);
CREATE TABLE `gorod_weapon` (
`id` INT NOT
NULL AUTO_INCREMENT ,
`name` VARCHAR( 50 ) NOT NULL ,
`dameg` INT NOT
NULL ,
`price` INT NOT NULL ,
PRIMARY KEY ( `id` )
);
CREATE TABLE
`gorod_security` (
`id` INT NOT NULL AUTO_INCREMENT ,
`name` VARCHAR( 50
) NOT NULL ,
`price` INT NOT NULL ,
`uron` INT NOT NULL ,
PRIMARY KEY (
`id` )
);
CREATE TABLE `gorod_para` (
`id` INT NOT NULL
AUTO_INCREMENT ,
`name` VARCHAR( 50 ) NOT NULL ,
`price` INT NOT NULL
,
`path` VARCHAR( 15 ) NOT NULL ,
PRIMARY KEY ( `id` )
);
CREATE
TABLE `gorod_invent` (
`id` INT NOT NULL AUTO_INCREMENT ,
`uid` INT NOT
NULL ,
`name` VARCHAR( 150 ) NOT NULL ,
`life` SMALLINT NOT NULL
,
`type` VARCHAR( 50 ) NOT NULL ,
`price` BIGINT NOT NULL ,
`uron` INT
NOT NULL,
PRIMARY KEY ( `id` )
);
CREATE TABLE `gorod_zaks` (
`id`
INT NOT NULL AUTO_INCREMENT ,
`date` BIGINT NOT NULL ,
`on` VARCHAR( 32 )
NOT NULL ,
`ona` VARCHAR( 32 ) NOT NULL ,
`onyes` VARCHAR( 3 ) NOT NULL
,
`onayes` VARCHAR( 3 ) NOT NULL ,
`avtor` VARCHAR( 32 ) NOT NULL
,
PRIMARY KEY ( `id` )
);
CREATE TABLE `gorod_zoo` (
`id` INT NOT
NULL AUTO_INCREMENT ,
`user` VARCHAR( 32 ) NOT NULL ,
`path` VARCHAR( 15
) NOT NULL ,
`name` VARCHAR( 32 ) NOT NULL ,
`where` VARCHAR( 32 ) NOT
NULL ,
`opis` VARCHAR( 150 ) NOT NULL ,
`fam` VARCHAR( 50 ) NOT NULL
,
`poroda` VARCHAR( 50 ) NOT NULL ,
PRIMARY KEY ( `id` )
);
CREATE
TABLE `gorod_tbega` (
`id` INT NOT NULL AUTO_INCREMENT ,
`name` VARCHAR(
32 ) NOT NULL ,
`bet` SMALLINT NOT NULL ,
`last` VARCHAR( 32 ) NOT NULL
,
PRIMARY KEY ( `id` )
);
ALTER TABLE `user` ADD `gorod_life`
SMALLINT NOT NULL ;
ALTER TABLE `user` ADD `gorod_eda_time` BIGINT NOT
NULL ;
ALTER TABLE `user` ADD `gorod_money` BIGINT NOT NULL ;
ALTER TABLE
`user` ADD `gorod_ohota_time` BIGINT NOT NULL ;
ALTER TABLE `user` ADD
`gorod_brak` VARCHAR( 32 ) NOT NULL ;
ALTER TABLE `user` ADD `gorod_tamag`
VARCHAR( 32 ) NOT NULL ;
ALTER TABLE `user` ADD `gorod_tamag_life`
SMALLINT NOT NULL ;
ALTER TABLE `user` ADD `gorod_tamag_time` BIGINT NOT
NULL ;
ALTER TABLE `user` ADD `gorod_voodoo` INT NOT NULL ,
ADD
`gorod_voodoo_name` VARCHAR( 32 ) NOT NULL ;
ALTER TABLE `user` ADD
`gorod_kopi` BIGINT NOT NULL ;
ALTER TABLE `user` ADD `gorod_kriminal` INT
NOT NULL ,
ADD `gorod_kriminal_time` BIGINT NOT NULL ;
ALTER TABLE `user`
ADD `gorod_security` VARCHAR( 32 ) NOT NULL ,
ADD `gorod_security_uron`
INT NOT NULL ;
ALTER TABLE `user` ADD `gorod_para` VARCHAR( 50 ) NOT NULL
;
ALTER TABLE `user` ADD `gorod_tur` VARCHAR( 50 ) NOT NULL ;
ALTER TABLE
`user` ADD `gorod_firm` VARCHAR( 50 ) NOT NULL ;
ALTER TABLE `user` ADD
`gorod_band` VARCHAR( 50 ) NOT NULL ;
ALTER TABLE `user` ADD
`gorod_band_time` BIGINT NOT NULL ;