Skip to content

Category Table Reference

mikert edited this page Feb 16, 2011 · 1 revision

Category Table Reference

Associated Perl classes

  • MT::Category
  • MT::Folder

Fields

  • category_id - integer not null auto_increment. - The primary key of the table.
  • category_blog_id - integer not null. - The blog associated with the category.
  • category_class - string(255). - A string which represens the Perl class for this entry.
    • category - MT::Category
    • folder - MT::Folder
  • category_created_by - integer. - The user that created the category.
  • category_created_on - datetime. - The date and time when the category was created.
  • category_label - string(100) not null. - The label of the category.
  • category_modified_by - integer. - The user who last modified the category.
  • category_modified_on - datetime. - The date and time when the category was last modified.
  • category_author_id - integer. - The user that owns the category.
  • category_ping_urls - text. - URLs to ping when updated.
  • category_description - text. - A description of the category.
  • category_parent - integer. - The ID number of the parent category.
  • category_allow_pings - boolean. - A flag which determines whether or not this category will accept trackbacks.
  • category_basename - string(255). - The basename of the category (a normalized version of the label field). This field is used in the construction of category archive URLs.

Indexes

  • mt_category_blog_id
  • mt_category_label
  • mt_category_parent
  • mt_category_blog_basename - columns:
    • blog_id
    • basename
  • mt_category_blog_class - columns:
    • blog_id
    • class

SQL example

SELECT 
    entry_title
    FROM mt_entry e 
    JOIN mt_placement p ON e.entry_id = p.placement_entry_id
    JOIN mt_category c ON c.category_id = p.placement_category_id 
    AND c.category_label LIKE 'Melody%'
Clone this wiki locally