Difference between revisions of "Character bind (Database Table)"
From SWGANH Wiki
(New page: <pre> CREATE TABLE `character_bind` ( `id` bigint(20) NOT NULL auto_increment COMMENT 'ID', `character_id` bigint(20) unsigned NOT NULL COMMENT 'Character ID', `bank_planet_id` int(2...) |
(→Table Describe) |
||
(5 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
+ | {{PageHeader|Database Table|biography_faction}} | ||
+ | |||
+ | {| border="0" width="90%" cellpadding=6 | ||
+ | |- | ||
+ | |valign=top| | ||
+ | |||
+ | ==Table Structure== | ||
+ | {| align="center" | ||
+ | |- | ||
+ | || | ||
+ | {| class = "wikitable" | ||
+ | |- align="center" style="background-color:#ffffcc;" | ||
+ | ||'''Field'''||'''Type'''||'''Unsigned'''||'''Autoinc'''||'''Null'''||'''Key'''||'''Default Value'''||'''Description''' | ||
+ | |- align="center" | ||
+ | |align="left"|id||BIGINT(20)|| || || ||[[Image:Symbol OK.png|10px]]||NULL||ID | ||
+ | |- align="center" style="background-color:#F1F1F1;" | ||
+ | |align="left"|character_id||BIGINT(20)||[[Image:Symbol OK.png|10px]]||[[Image:Symbol OK.png|10px]]||[[Image:Symbol OK.png|10px]]|| || ||Character ID (swganh.characters) | ||
+ | |- align="center" | ||
+ | |align="left"|bank_planet_id||INT(2)|| || ||[[Image:Symbol OK.png|10px]]|| ||NULL||Planet ID (swganh.planets) | ||
+ | |- align="center" style="background-color:#F1F1F1;" | ||
+ | |align="left"|bind_oX||FLOAT(10,6)|| || ||[[Image:Symbol OK.png|10px]]|| ||NULL||Bind Location X | ||
+ | |- align="center" | ||
+ | |align="left"|bind_oY||FLOAT(10,6)|| || ||[[Image:Symbol OK.png|10px]]|| ||NULL||Bind Location Y | ||
+ | |- align="center" style="background-color:#F1F1F1;" | ||
+ | |align="left"|bind_oZ||FLOAT(10,6)|| || ||[[Image:Symbol OK.png|10px]]|| ||NULL||Bind Location Z | ||
+ | |- align="center" | ||
+ | |align="left"|clone_city_id||INT(10)||[[Image:Symbol OK.png|10px]]|| ||[[Image:Symbol OK.png|10px]]|| ||NULL||Clone Location (swganh.spawn_clone) | ||
+ | |- | ||
+ | |} | ||
+ | |} | ||
+ | |||
+ | |valign=top| | ||
+ | |||
+ | == Related Tags == | ||
+ | {|align="center" | ||
+ | |- | ||
+ | ||{{D100%}} | ||
+ | |- | ||
+ | ||{{Database}} | ||
+ | |- | ||
+ | ||{{DatabaseTable}} | ||
+ | |- | ||
+ | |} | ||
+ | |} | ||
+ | |||
+ | ==Table Create Script== | ||
<pre> | <pre> | ||
CREATE TABLE `character_bind` ( | CREATE TABLE `character_bind` ( | ||
`id` bigint(20) NOT NULL auto_increment COMMENT 'ID', | `id` bigint(20) NOT NULL auto_increment COMMENT 'ID', | ||
`character_id` bigint(20) unsigned NOT NULL COMMENT 'Character ID', | `character_id` bigint(20) unsigned NOT NULL COMMENT 'Character ID', | ||
− | `bank_planet_id` int(2) | + | `bank_planet_id` int(2) default '255' COMMENT 'Planet ID for Bank', |
− | `bind_oX` float(10,6) | + | `bind_oX` float(10,6) default NULL COMMENT 'X Location - Bind', |
− | `bind_oY` float(10,6) | + | `bind_oY` float(10,6) default NULL COMMENT 'Y Location - Bind', |
− | `bind_oZ` float(10,6) | + | `bind_oZ` float(10,6) default NULL COMMENT 'Z Location - Bind', |
− | `clone_city_id` int(10) unsigned | + | `clone_city_id` int(10) unsigned default NULL COMMENT 'Clone City ID', |
PRIMARY KEY (`id`), | PRIMARY KEY (`id`), | ||
KEY `FK_character_bind_1` (`character_id`), | KEY `FK_character_bind_1` (`character_id`), | ||
KEY `FK_character_bind_2` (`bank_planet_id`), | KEY `FK_character_bind_2` (`bank_planet_id`), | ||
KEY `FK_character_bind_3` (`clone_city_id`), | KEY `FK_character_bind_3` (`clone_city_id`), | ||
− | |||
CONSTRAINT `FK_character_bind_1` FOREIGN KEY (`character_id`) REFERENCES `characters` (`id`) ON DELETE CASCADE ON UPDATE CASCADE, | CONSTRAINT `FK_character_bind_1` FOREIGN KEY (`character_id`) REFERENCES `characters` (`id`) ON DELETE CASCADE ON UPDATE CASCADE, | ||
− | CONSTRAINT `FK_character_bind_2` FOREIGN KEY (`bank_planet_id`) REFERENCES `planet` (`planet_id`) ON DELETE CASCADE ON UPDATE CASCADE | + | CONSTRAINT `FK_character_bind_2` FOREIGN KEY (`bank_planet_id`) REFERENCES `planet` (`planet_id`) ON DELETE CASCADE ON UPDATE CASCADE, |
+ | CONSTRAINT `FK_character_bind_3` FOREIGN KEY (`clone_city_id`) REFERENCES `spawn_clone` (`id`) ON DELETE CASCADE ON UPDATE CASCADE | ||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Character Bind Data'; | ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Character Bind Data'; | ||
+ | </pre> | ||
+ | |||
+ | ==Table Describe== | ||
+ | <pre> | ||
+ | mysql> desc character_bind; | ||
+ | +----------------+---------------------+------+-----+---------+----------------+ | ||
+ | | Field | Type | Null | Key | Default | Extra | | ||
+ | +----------------+---------------------+------+-----+---------+----------------+ | ||
+ | | id | bigint(20) | NO | PRI | NULL | auto_increment | | ||
+ | | character_id | bigint(20) unsigned | NO | MUL | | | | ||
+ | | bank_planet_id | int(2) | YES | MUL | 255 | | | ||
+ | | bind_oX | float(10,6) | YES | | NULL | | | ||
+ | | bind_oY | float(10,6) | YES | | NULL | | | ||
+ | | bind_oZ | float(10,6) | YES | | NULL | | | ||
+ | | clone_city_id | int(10) unsigned | YES | MUL | NULL | | | ||
+ | +----------------+---------------------+------+-----+---------+----------------+ | ||
+ | 7 rows in set (0.00 sec) | ||
</pre> | </pre> |
Latest revision as of 13:27, 7 September 2007
Database Table - biography_faction
SWGANH Wiki is a repository of Star Wars Galaxies Developer information. This site is only meant to be used by SWGANH Developer team.
Table Create Script
CREATE TABLE `character_bind` ( `id` bigint(20) NOT NULL auto_increment COMMENT 'ID', `character_id` bigint(20) unsigned NOT NULL COMMENT 'Character ID', `bank_planet_id` int(2) default '255' COMMENT 'Planet ID for Bank', `bind_oX` float(10,6) default NULL COMMENT 'X Location - Bind', `bind_oY` float(10,6) default NULL COMMENT 'Y Location - Bind', `bind_oZ` float(10,6) default NULL COMMENT 'Z Location - Bind', `clone_city_id` int(10) unsigned default NULL COMMENT 'Clone City ID', PRIMARY KEY (`id`), KEY `FK_character_bind_1` (`character_id`), KEY `FK_character_bind_2` (`bank_planet_id`), KEY `FK_character_bind_3` (`clone_city_id`), CONSTRAINT `FK_character_bind_1` FOREIGN KEY (`character_id`) REFERENCES `characters` (`id`) ON DELETE CASCADE ON UPDATE CASCADE, CONSTRAINT `FK_character_bind_2` FOREIGN KEY (`bank_planet_id`) REFERENCES `planet` (`planet_id`) ON DELETE CASCADE ON UPDATE CASCADE, CONSTRAINT `FK_character_bind_3` FOREIGN KEY (`clone_city_id`) REFERENCES `spawn_clone` (`id`) ON DELETE CASCADE ON UPDATE CASCADE ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Character Bind Data';
Table Describe
mysql> desc character_bind; +----------------+---------------------+------+-----+---------+----------------+ | Field | Type | Null | Key | Default | Extra | +----------------+---------------------+------+-----+---------+----------------+ | id | bigint(20) | NO | PRI | NULL | auto_increment | | character_id | bigint(20) unsigned | NO | MUL | | | | bank_planet_id | int(2) | YES | MUL | 255 | | | bind_oX | float(10,6) | YES | | NULL | | | bind_oY | float(10,6) | YES | | NULL | | | bind_oZ | float(10,6) | YES | | NULL | | | clone_city_id | int(10) unsigned | YES | MUL | NULL | | +----------------+---------------------+------+-----+---------+----------------+ 7 rows in set (0.00 sec)