Semantic MediaWiki/data/smw text2
< Semantic MediaWiki | data
Jump to navigation
Jump to search
About
- Version: 1.7
- Documentation status: unofficial; confirmed only by testing
- Purpose: defines semantic relationships between property-names and property-values, where the value-type is long text or data of some kind (no SMW ID)
- Fields:
SQL
<mysql>CREATE TABLE `smw_text2` (
`s_id` int(8) unsigned NOT NULL, `p_id` int(8) unsigned NOT NULL, `value_blob` mediumblob, KEY `s_id` (`s_id`), KEY `p_id` (`p_id`)
) ENGINE=InnoDB DEFAULT CHARSET=binary;</mysql>
Examples
<mysql> SELECT s_id, p_id
, CAST(s.smw_title AS char) AS s_title , CAST(p.smw_title AS char) AS p_title , CAST(t.value_blob AS char) AS t_value FROM (smw_text2 AS t LEFT JOIN smw_ids AS s ON t.s_id=s.smw_id) LEFT JOIN smw_ids AS p ON t.p_id=p.smw_id;
</mysql>