Catalog

 view release on metacpan or  search on metacpan

lib/Catalog/mysql/schema.pm  view on Meta::CPAN


  #
  # Authorization bound to a specific catalog
  #

  #
  # Name of the catalog on which this entry applies
  #
  catalogname varchar(32) not null,

  #
  # Allow everything on this catalog
  #
  catalogsuperuser char(1) not null default 'n',

  #
  # Authorization on a specific theme category
  #

  #
  # Link to the category (catalog_category_NAME) 
  #
  categorypointer int not null default 0,
  #
  # Allow sub category add/edit/remove
  #
  categorysubedit char(1) not null default 'n',
  #
  # Allow entries add/edit/remove
  #
  categoryentryedit char(1) not null default 'n',


  unique catalog_auth_categories1 (rowid),
  index catalog_auth_categories2 (auth),
  index catalog_auth_categories3 (catalogname),
  index catalog_auth_categories4 (categorypointer)
)
",
		    'catalog_entry2category' => "
create table catalog_entry2category_NAME (
  #
  # Table management information 
  #
  created datetime not null,
  modified timestamp not null,

  #
  # State information
  #
  info set ('hidden'),
  #
  # Rowid of the record from catalogued table
  #
  row int not null,
  #
  # Rowid of the category
  #
  category int not null,
  #
  # External identifier to synchronize with alien catalogs
  #
  externalid varchar(32) not null default '',

  index catalog_entry2category_NAME2 (created),
  index catalog_entry2category_NAME3 (modified),
  unique catalog_entry2category_NAME4 (row,category),
  index catalog_entry2category_NAME5 (category),
  index catalog_entry2category_NAME6 (externalid)
)
",
		    'catalog_category' => "
create table catalog_category_NAME (
  #
  # Table management information 
  #
  rowid int $autoinc,
  created datetime not null,
  modified timestamp not null,

  #
  # State information
  # root : set on root category
  # displaygrandchild : set if the category is to be shown
  #               if the template that displays the children of
  #               a category also displays grand children.
  #
  info set ('root', 'displaygrandchild'),
  #
  # Full name of the category
  #
  name varchar(255) not null,
  #
  # Total number of records in this category and bellow
  #
  count int default 0,
  #
  # External identifier to synchronize with alien catalogs
  #
  externalid varchar(32) not null default '',

  unique catalog_category_NAME1 (rowid),
  index catalog_category_NAME2 (created),
  index catalog_category_NAME3 (modified),
  index catalog_category_NAME4 (name(122)),
  index catalog_category_NAME5 (externalid)
)
",
		    'catalog_path' => "
create table catalog_path_NAME (
  #
  # Full path name of the category
  #
  pathname text not null,
  #
  # MD5 key of the path name
  #
  md5 char(32) not null,
  #
  # Full path name translated to ids
  #
  path varchar(255) not null,
  #
  # Id of the last component
  #
  id int not null,

  unique catalog_path_NAME1 (md5),
  unique catalog_path_NAME2 (path),
  unique catalog_path_NAME3 (id)
)
",
		    'catalog_alpha' => "
create table catalog_alpha_NAME (
  #
  # Table management information 
  #
  rowid int $autoinc,
  created datetime not null,
  modified timestamp not null,

  #
  # The letter
  #
  letter char(1) not null,
  #
  # Count of records of the catalogued table have
  # a field starting with this letter.
  #
  count int default 0,

  unique catalog_alpha_NAME1 (rowid)
)
",
		    'catalog_date' => "
create table catalog_date_NAME (
  #
  # Table management information 
  #
  rowid int $autoinc,

  #
  # The date interval
  #
  tag char(8) not null,
  #
  # Count of records of the catalogued table have
  # a field starting with this letter.
  #
  count int default 0,

  unique catalog_date_NAME1 (rowid),
  unique catalog_date_NAME2 (tag)
)
",
		    'catalog_category2category' => "
create table catalog_category2category_NAME (
  #
  # Table management information 
  #
  rowid int $autoinc,
  created datetime not null,
  modified timestamp not null,

  #
  # State information
  #
  info set ('hidden', 'symlink'),
  #
  # Rowid of father
  #
  up int not null,
  #
  # Rowid of child
  #
  down int not null,
  #
  # External identifier to synchronize with alien catalogs
  #
  externalid varchar(32) not null default '',

  unique catalog_category2category_NAME1 (rowid),
  index catalog_category2category_NAME2 (created),
  index catalog_category2category_NAME3 (modified),
  unique catalog_category2category_NAME4 (up,down),
  index catalog_category2category_NAME5 (down),
  index catalog_category2category_NAME6 (externalid)
)
",
	            'catalog_unload' => "
create table catalog_unload_NAME (
rowid int not null,
unique catalogunloadNAME (rowid)
)
",
	            'urldemo' => "
create table urldemo (
  #
  # Table management information 
  #
  rowid int $autoinc,
  created datetime not null,
  modified timestamp not null,

  info enum ('active', 'inactive') default 'active',
  url char(128),
  comment char(255),

  unique cdemo1 (rowid)
)
",
		    };

1;
# Local Variables: ***
# mode: perl ***
# End: ***



( run in 2.280 seconds using v1.01-cache-2.11-cpan-2398b32b56e )