Learn More





DNN Community Blog

The Community Blog is a personal opinion of community members and by no means the official standpoint of DNN Corp or DNN Platform. This is a place to express personal thoughts about DNNPlatform, the community and its ecosystem. Do you have useful information that you would like to share with the DNN Community in a featured article or blog? If so, please contact .

The use of the Community Blog is covered by our Community Blog Guidelines - please read before commenting or posting.

Content, MetaData and Taxonomy – 2 – Overview of the Data Layer

This article is cross-posted from my personal blog.

In DotNetNuke version 5.3, we introduced the concept of a centralized Content store, together with the ability to apply Taxonomies (categories) to the content.  We have extended this in DNN 5.4 by completing the MetaData API as well as adding Folksonomy (user tags).

In this series of blogs I will explain how developers can take advantage of these new features in their own extensions.

In the first blog in this series I covered the Taxonomy Manager and how an admin can use the new taxonomy features.  Next I will review the Data Structue for these components


Figure 1 shows the ContentItems and ContentTypes tables. 

Figure 1: The ContentItems and ContentTypes Tables


Most of the columns in the ContentItems Table are self-explanatory, but for completeness they are summarized below:

  • ContentItemID – Primary Key Identity column
  • ContentTypeID – Foreign Key to the ContentTypes Table
  • TabID – The tab/page where the content belongs
  • ModuleID – the module which “owns” the content
  • Content – the content
  • ContentKey – a key which uniquely identifies the Content Item
  • Indexed – for future use when Search is integrated
  • CreatedByUserID, CreatedOnDate, LastModifiedByUserID, LastModifiedOnDate – standard audit fields

The ContentTypes Table is a look-up table which defines various types of content – by default two types are defined – Tab/Page and Module.  Module Developers are free to add their own Content Types – for example Blog Post or Forum Post.


Each ContentItem can have many related items of MetaData (see Figure 2)

Figure 2: Content MetaData Tables


The MetaData table defines the types of MetaData, while the ContentItems_MetaData join table provides the many-to-many relationship, together with a value for the MetaData.  By default DNN will define the 15 types of MetaData defined by the Dublin Core standard

  1. Title
  2. Creator
  3. Subject
  4. Description
  5. Publisher
  6. Contributor
  7. Date
  8. Type
  9. Format
  10. Identifier
  11. Source
  12. Language
  13. Relation
  14. Coverage
  15. Rights

However, the API supports the addition of other MetaData types.  It should be noted that their is no restriction in the number of each MetaData item.  For example a piece of content could have 3 Sources or a Creator and multiple Contributors.

Vocabularies and Terms

In addition to defining MetaData for a piece of content, we have added support for a rich taxonomy/folksonomy.  Taxonomy is defined as “the practice and science of classification” – Wikipedia, while Folksonomy is defined as “collaborative tagging” – Wikipedia

Usually, taxonomy refers to the practice of using hierarchical categories applied to the content by a “content editor”, while folksonomy refers to the practice of free-form tagging of content by users. 

In DotNetNuke, while we expose both of these at the presentation layer, in the API and Data Layer they are implemented using a common data structure.

Figure 3: Vocabularies and Terms Tables


(Click on the image to see a larger version)

In DNN you can create multiple Vocabularies.  A Vocabulary is a collection of terms that relate to each other.  For example we could define a Vocabulary of Electronics terms or a Vocabulary of Colors.  Let’s first look at the columns defined in the Vocabularies Table

  • VocabularyID – Primary Key Identity column
  • VocabularyTypeID – Foreign Key to the VocabularyTypes table – this defines the types of vocabulary – we currently support two types a hierarchical Vocabulary and a simple (or flat) Vocabulary.
  • Name – the Name of the Vocabulary
  • Description – a Description for the Vocabulary
  • Weight – unused – but is intended to provide a mechanism to sort the Vocabularies
  • ScopeTypeID – A Foreign Key to the ScopeTypes table – this defines a scope for the vocabulary – we currently support two scopes – Application and Portal/Site
  • ScopeID – Used in conjunction with the ScopeTypeID – if the scope type is “Portal” this will be the PortalID for which this vocabulary is scoped
  • IsSystem – a flag which identifies this vocabulary as a “System” Vocabulary – one which cannot be deleted.
  • CreatedByUserID, CreatedOnDate, LastModifiedByUserID, LastModifiedOnDate – standard audit fields

For the Terms Table we have the following columns.

  • TermID – Primary Key Identity column
  • VocabularyID – Foreign Key to “parent” Vocabulary table
  • ParentTermID – Parent Term in hierarchical Vocabularies
  • Name – the Name of the Term
  • Description – a Description for the Term
  • Weight – unused – but is intended to provide a mechanism to sort the Terms
  • TermLeft, TermRight – used in the “Nested-Set” method of storing a heirarchical structure in a flat table – more in a future blog.
  • CreatedByUserID, CreatedOnDate, LastModifiedByUserID, LastModifiedOnDate – standard audit fields

DNN 5.4 adds a new System Vocabulary called Tags.  This Vocabulary is where the user-entered tags (folksonomy) are stored.

This blog is an overview of the Data Structure of the Content/Taxonomy features.  In the next blog I will go into detail on the “Nested Set” design used for the storage of hierarchical terms in the flat Terms table.


Chinna Botla

I am using DNN for one of my website, recently I heard about this Dublin Core, Can any one please suggest me in detail how can I use Duplin Core for my DNN website.

Chinna Botla Monday, January 20, 2014 6:44 AM (link)
Amanda Thomas
Hi, I know this is an old post, but.... is there an explanation anywhere online now of how TermLeft and TermRight work in the Taxonomy_Terms table? I think this may what's giving me issues.
Amanda Thomas Wednesday, October 29, 2014 5:32 PM (link)

Comment Form

Only registered users may post comments.


2sic Daniel Mettler (124)
Aderson Oliveira (15)
Alec Whittington (11)
Alex Shirley (10)
Andrew Nurse (30)
Anthony Glenwright (5)
Antonio Chagoury (28)
Ash Prasad (21)
Ben Schmidt (1)
Benjamin Hermann (25)
Benoit Sarton (9)
Beth Firebaugh (12)
Bill Walker (36)
Bob Kruger (5)
Brian Dukes (2)
Brice Snow (1)
Bruce Chapman (20)
Bryan Andrews (1)
cathal connolly (55)
Charles Nurse (163)
Chris Hammond (203)
Chris Paterra (55)
Clinton Patterson (28)
Cuong Dang (21)
Daniel Bartholomew (2)
Dave Buckner (2)
David Poindexter (3)
David Rodriguez (2)
Doug Howell (11)
Erik van Ballegoij (30)
Ernst Peter Tamminga (74)
Geoff Barlow (6)
Gifford Watkins (3)
Gilles Le Pigocher (3)
Ian Robinson (7)
Israel Martinez (17)
Jan Blomquist (2)
Jan Jonas (3)
Jaspreet Bhatia (1)
Jenni Merrifield (6)
Joe Brinkman (269)
John Mitchell (1)
Jon Henning (14)
Jonathan Sheely (4)
Jordan Coopersmith (1)
Joseph Craig (2)
Kan Ma (1)
Keivan Beigi (3)
Ken Grierson (10)
Kevin Schreiner (6)
Leigh Pointer (31)
Lorraine Young (60)
Malik Khan (1)
Matthias Schlomann (15)
Mauricio Márquez (5)
Michael Doxsey (7)
Michael Tobisch (3)
Michael Washington (202)
Mike Horton (19)
Mitchel Sellers (28)
Nathan Rover (3)
Navin V Nagiah (14)
Néstor Sánchez (31)
Nik Kalyani (14)
Peter Donker (52)
Philip Beadle (135)
Philipp Becker (4)
Richard Dumas (22)
Robert J Collins (5)
Roger Selwyn (8)
Ruben Lopez (1)
Ryan Martinez (1)
Salar Golestanian (4)
Sanjay Mehrotra (9)
Scott McCulloch (1)
Scott S (11)
Scott Wilkinson (3)
Scott Willhite (97)
Sebastian Leupold (80)
Shaun Walker (237)
Shawn Mehaffie (17)
Stefan Cullmann (12)
Stefan Kamphuis (12)
Steve Fabian (31)
Timo Breumelhof (24)
Tony Henrich (3)
Torsten Weggen (2)
Vicenç Masanas (27)
Vincent Nguyen (3)
Vitaly Kozadayev (6)
Will Morgenweck (37)
Will Strohl (163)
William Severance (5)
Try Evoq
For Free
Start Free Trial
a Demo
See Evoq Live
Need More Information?