[dokusite] 1.4.1.1. Database Table

"Roger Fischer" <[email protected]>
Newsgroups gmane.comp.cms.bitflux.general.german
Message-ID <[email protected]>
1.4.1.1. Database
1.4.1.2. Form
1.4.1.3. Structure XML
1.4.1.4. XSL Stylesheet


1.4.1.1 Database Table
======================
- First inspiration: Article Object
- Second inspiration: Docbook Chapter
- Final Database Table Chapter
- Chapter as XML


First inspiration: Article Objekt
---------------------------------

See Table Article:

CREATE TABLE Article (
  ID int(11) NOT NULL auto_increment,
  lang char(2) default 'de',
  title varchar(250) NOT NULL default '',
  subtitle varchar(250) default NULL,
  articleinfo_keywordset text,
  abstract text,
  main longtext,
  created datetime NOT NULL default '0000-00-00 00:00:00',
  createdby varchar(50) NOT NULL default 'someone',
  changed timestamp(14) NOT NULL,
  changedby varchar(50) NOT NULL default 'someone',
  PRIMARY KEY  (ID)
) TYPE=MyISAM;


Second inspiration: Docbook Chapter
-----------------------------------
See at:
http://docbook.org/tdg/en/html/chapter.html


Final Database Table Chapter
----------------------------

CREATE TABLE Chapter (
  ID int(11) NOT NULL auto_increment,
  lang char(2) default 'de',
  title varchar(250) NOT NULL default '',
  subtitle varchar(250) default NULL,
  chapterinfo_keywordset text,
  abstract text,
  main longtext,
  created datetime NOT NULL default '0000-00-00 00:00:00',
  createdby varchar(50) NOT NULL default 'someone',
  changed timestamp(14) NOT NULL,
  changedby varchar(50) NOT NULL default 'someone',
  PRIMARY KEY  (ID)
) TYPE=MyISAM;


WARNING:
Not conform with Docbook: the Element "main", Docbook doesn't know this
element. But it would be very easy to transform that back to Docbook.

Chapter as XML
--------------
In XML Chapter would then look something like this:

<Chapter id="ChapterID">
	<ID>ID</ID>
	<lang>de</lang>
	<title>Chaptertitle</title>
	<subtitle>Chaptersubtitle</subtitle>
	<chapterinfo>
		<keywordset>
			<keyword>Keyword</keyword>
		</keywordset>
	</chapterinfo>
	<abstract>
		<para>Some Abstract about this Chapter</para>
	</abstract>
	<main>
		<section>
			<title>A section title</section>
			<para>A para</para>
		</section>
	</main>
</Chapter>





--
roger fischer | bitflux GmbH | schöneggstrasse 5 | ch-8004 zürich
tel +41 1 240 56 72 | mobil +41 78 607 75 06 | fax +41 1 240 56 71
http://www.bitflux.ch | [email protected]

OSCOM - Open Source Content Management
http://www.oscom.org
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.