More in this section

Forums / Developing with Sitefinity / Content Items in the DB

Content Items in the DB

4 posts, 0 answered
  1. Mike
    Mike avatar
    221 posts
    Registered:
    19 Aug 2008
    24 Feb 2009
    Link to this post
    This is going to be a very general question. Basically we have a bridge table in our database, we want to be able to bridge the content items with our data that exists... we would then simply create a module that sets up the bridging and level the creating of the content existing SiteFinity modules.

    But we are not even close to this point with it... This is why my questions are general, here they are:

    1. Where does SF store content items and page andimage in the DB.
    2. Could someone give me a general overview of in what format/type are they stored in the DB
    3. If we wanted to add columns to the SF tables, could we do this without disrupting the existing functionality?
    4. SF stores image and html content and pages in the DB, are all these held in the same table in the DB?
    Thanks,

    Duncan
  2. Pierre
    Pierre avatar
    433 posts
    Registered:
    16 Feb 2006
    24 Feb 2009
    Link to this post
    Hi Duncan,

    I can share my some of work. Basically the items are stored as Metafields in the table sf_GCMetaData. you can open and see the contents. In this table you can see the format and you others questions. After if you need to add some content I suggest you not modify the table structure but use the metafields to add your contents inside. If you need to link with some external tool you can use some codebehind linked to the Modules to read , modify or update your contents during the same events to external tables. Sample. After open the Edit/Insert templates you can create some events to save in external databases or mixed. I have used one solution like that to build complexe solution where the items are added as custom Metafields, Files in folders, images in Folders, videos in Folders, sounds and stored someones in Sf tables and other in my custom tables under the same database. If you like to build one special Module to make the transfert that is another problem. I'm also interesed if someone post some tips and the way. Regards.
  3. Mike
    Mike avatar
    221 posts
    Registered:
    19 Aug 2008
    24 Feb 2009
    Link to this post
    Thanks for all the replies today Pierre - i really appreciate it...

    I am looking at the SF_GCMETADATA table that you mentioned... Very interesting.... I see my library items and some of the shared generic content... But i think the table i am most interested in is the one that holder the page content...

    Let me explain:

    Say i access the CMS and create a new page, i then drag the Generic Content control onto the page - add some content and publish the page out...

    This content is not in the SF_GCMETADATA table as far as i can see... I do see a SF_CMSPAGECONTENT table but no blob or binary data/column that would hold the page content...

    In any case what you have mentioned is very helpful! Thank you!

    Duncan
  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    26 Feb 2009
    Link to this post
    Hi Duncan,

    These values are control properties. For instance if you want to get the content of the GeneriContent control you could run the following query to sf_CmsControlProperty.

    select * from sf_CmsControlProperty where Name = 'Content' 

    I hope this helps.

    Greetings,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
Register for webinar
4 posts, 0 answered