Types of Database Tables

We will now discuss about the Database tables in Fatwire. There are five different types of tables in the Content Server database:

  1. Object tables
  2. Tree tables
  3. Content tables
  4. Foreign tables
  5. System tables
Object Tables

These tables hold the data as objects and provide a unique identifier for each row in the table. Object tables store data as an object and can be represented in hierarchies. The primary key for object tables is always the ID (id) column and that cannot be changed. When we add an object table, it creates an ID column automatically in that table.

Tree Tables

These tables hold the hierarchical information about relationships between objects in object table, i.e., the object tables can be represented in hierarchies, but the hierarchy itself is stored in a tree table — the hierarchy is the tree.

The examples of tree tables are:

  1. AssetRelationTree
  2. SitePlanTree
Content Tables

Content tables store data as flat data (rather than as objects) and that information cannot be organized in a hierarchy. You use content tables for simple lookup tables. The CS doesn’t provide a unique identifier for the rows in the table.

Foreign Tables

A foreign table is one that Content Server does not completely manage. These can be the tables which can be:

Tables that are outside of the Content Server database but that Content Server has access to.

Tables that are in the Content Server database but that Content Server did not create.

Content Server can query foreign tables and cache the resultsets just as it does for its own object and content tables.

System Tables

These are core Content Server application tables. The schema of these tables cannot be modified, i.e., these are the Content Server tables whose schema is fixed. You can add rows to some of the system tables (say using the Content Server Explorer tool or using some other way), but you cannot add or modify the columns in these tables in any way. Also, we cannot add system tables to the database.

The examples of System Tables are:

  1. ElementCatalog
  2. SiteCatalog
  3. SystemACL
  4. SystemInfo
  5. SystemPageCache
  6. SystemUsers .. etc…
How to know the Table’s Type:

We can identify the type of any table using the SystemInfo table. The system table is the one that lists all the tables in the database.

Following are the steps to identify the Table’s type:

  1. Open the Content Server Explorer and log in to the Content Server database.
  2. Open the SystemInfo table.
  3. Examine the systable column. The value in this column identifies the type of table represented in the row. Refer the screen below:

Untitled

Here are the codes for identifying the tables:

  1. YES = System table
  2. NO = Content table
  3. OBJ = Object table
  4. TREE = Tree table
  5. FGN = Foreign table
Advertisements
Comments
  1. Ghazi Hakim says:

    Hello,

    I need to create a table to save the content of an excel file uploaded by an end user,
    I want this table to be managed by Content Server so I can use sql tags ..
    I’m working with fatwire 7.6.2 and when I go to Admin > Content Server Management Tools > Content Server Database, I enter the name of my table and I choose “Add Table”,
    Then it ask me to provide the “File Storage Directory” and the table type (Content or Object),
    I don’t really know what type is better for my needs neither the utility of a file storage directory..
    Can you help me please ?

    Regards,
    Ghazi.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s