The "xwikidoc" Table

The xwikidoc table corresponds to the com.xpn.xwiki.doc.XWikiDocument class and it stores information about the XWiki pages.

The mapping information is available in the xwiki.hbm.xml file:

<class name="com.xpn.xwiki.doc.XWikiDocument" table="xwikidoc">
 <id name="id" type="long" unsaved-value="undefined">
   <column name="XWD_ID" not-null="true" />
   <generator class="assigned" />
 </id>
 <property name="fullName" type="string" column="XWD_FULLNAME" length="255" index="DOC_FULLNAME" not-null="true" />
 <property name="name" type="string" column="XWD_NAME" length="255" index="DOC_NAME" not-null="true" />
 <property name="title" type="string" column="XWD_TITLE" length="255" index="DOC_TITLE" not-null="true" />
 <property name="language" type="string" column="XWD_LANGUAGE" index="DOC_LANGUAGE" length="5" />
 <property name="defaultLanguage" type="string" column="XWD_DEFAULT_LANGUAGE" index="DOC_DEFAULT_LANGUAGE" length="5" />
 <property name="translation" type="integer" column="XWD_TRANSLATION" not-null="true" />
 <property name="date" type="timestamp" column="XWD_DATE" index="DOC_DATE" not-null="true" />
 <property name="contentUpdateDate" type="timestamp" column="XWD_CONTENT_UPDATE_DATE" index="DOC_CONTENT_UPDATE_DATE" not-null="true" />
 <property name="creationDate" type="timestamp" column="XWD_CREATION_DATE" index="DOC_CREATION_DATE" not-null="true" />
 <property name="author" type="string" column="XWD_AUTHOR" length="255" index="DOC_AUTHOR" not-null="true" />
 <property name="contentAuthor" type="string" column="XWD_CONTENT_AUTHOR" length="255" index="DOC_CONTENT_AUTHOR" not-null="true" />
 <property name="creator" type="string" column="XWD_CREATOR" length="255" index="DOC_CREATOR" not-null="true" />
 <!-- This property is deprecated and should not be used anymore. Use .space instead. -->
 <property name="web" type="string" update="false" insert="false" column="XWD_WEB" length="255" not-null="true" />
 <property name="space" type="string" column="XWD_WEB" length="255" index="DOC_SPACE" not-null="true" />
 <property name="content" type="text" column="XWD_CONTENT" length="200000" not-null="true" />
 <property name="version" type="string" column="XWD_VERSION" length="255" not-null="true" />
 <property name="customClass" type="string" column="XWD_CUSTOM_CLASS" length="255" not-null="true" />
 <property name="parent" type="string" column="XWD_PARENT" length="511" not-null="true" />
 <property name="xWikiClassXML" type="text" column="XWD_CLASS_XML" length="60000" not-null="false" />
 <property name="elements" type="integer" not-null="true" column="XWD_ELEMENTS" />
 <property name="defaultTemplate" type="string" column="XWD_DEFAULT_TEMPLATE" not-null="true" />
 <property name="validationScript" type="string" column="XWD_VALIDATION_SCRIPT" not-null="true" />
 <property name="comment" type="string" column="XWD_COMMENT" length="1023" not-null="true" />
 <property name="minorEdit1" type="boolean" column="XWD_MINOREDIT" index="DOC_MINOREDIT" not-null="true" />
 <property name="syntaxId" type="string" column="XWD_SYNTAX_ID" length="50" />
 <property name="hidden" type="boolean" column="XWD_HIDDEN" index="DOC_HIDDEN" not-null="true" />
</class>

The columns of the xwikidoc table are:

ColumnData typeClass propertyIndex
XWD_ID (primary key; it is a number generated by taking a hash code of the database name and XWD_FULLNAME)bigint(20)- -
XWD_FULLNAMEvarchar(255)fullNameDOC_FULLNAME
XWD_NAMEvarchar(255)nameDOC_NAME
XWD_TITLEvarchar(255)titleDOC_TITLE
XWD_LANGUAGEvarchar(5)languageDOC_LANGUAGE
XWD_DEFAULT_LANGUAGEvarchar(5)defaultLanguageDOC_DEFAULT_LANGUAGE
XWD_TRANSLATION (for regular documents the value is 0 whereas for document translations the value is 1)int(11)translation-
XWD_DATEdatetimedateDOC_DATE
XWD_CONTENT_UPDATE_DATEdatetimecontentUpdateDateDOC_CONTENT_UPDATE_DATE
XWD_CREATION_DATE datetimecreationDateDOC_CREATION_DATE
XWD_AUTHORvarchar(255)authorDOC_AUTHOR
XWD_CONTENT_AUTHOR varchar(255)contentAuthorDOC_CONTENT_AUTHOR
XWD_CREATOR varchar(255)creatorDOC_CREATOR
XWD_WEB (marked as deprecated and no longer used when updating the table)varchar(255)
varchar(255)
web
space
-
DOC_SPACE
XWD_CONTENTlongtextcontent-
XWD_VERSION varchar(255)version-
XWD_CUSTOM_CLASS varchar(255)customClass -
XWD_PARENT varchar(511)parent-
XWD_CLASS_XML longtextxWikiClassXML-
XWD_ELEMENTS int(11)elements-
XWD_DEFAULT_TEMPLATEvarchar(255)defaultTemplate-
XWD_VALIDATION_SCRIPTvarchar(255)validationScript-
XWD_COMMENT varchar(1023)comment-
XWD_MINOREDIT bit(1)minorEdit1DOC_MINOREDIT
XWD_SYNTAX_ID varchar(511)syntaxId-
XWD_HIDDENbit(1)hiddenDOC_HIDDEN

 

Search this space