User login
Navigation
Recent blog posts
- Ubuntu mirrors up and improved!
- Google-jstemplate: Iterate object with unknown properties
- nginx https proxypass for php apps
- sugarcrm & memcache: Doing it Wrong
- subversion and https in Ubuntu Karmic
- Drupal: Views block delta converted to md5 hash
- Ubuntu Server install requires PAE
- Installing Drupal from command line
- Drupal: Handling form field weight through CCK
- minify javascript using Google Closure Compiler
angch's location
angch twitter
Drupal: Where's my CCK content get stored in db ?

kamal — Tue, 16/06/2009 - 12:10
Wrote about internal CCK storage in my personal blog sometimes ago but looking through issues coming up recently in our issue tracker suggest that some of developers here still not sure where their CCK content are stored in the database. Briefly revising this topic to give some clue on where to look after when something goes wrong with our CCK related content.
Here it goes:-
- Node is stored inside
nodetable with a columnnidandvidto uniquely identified the node. This should be obvious to everyone developing with Drupal. - When creating new content type, let say
building, a new table namedcontent_type_buildingis created. This table would contain columnsnidandvidplus all defined fields for that content type in the form offield_<field_name>_value. - If field we added to that content type is a shared field, new table would be created (if not exist) named as
content_field_<field_name>with 3 columns -nid,vid,field_<field_name>_value. This is where content for this field get stored.
So basically all your content would be stored in 2 (or 3) different tables depending whether your field is shared or not.
