Database ERD (2.0.1)

mikeraynham edited this page May 24, 2011 · 2 revisions

Bricolage 2.0.1 Database Entity Relation Diagram (3576×2318 PNG)





Table action
id serial NOT NULL
ord int2 NOT NULL
server_type__id int4 NOT NULL
action_type__id int4 NOT NULL
active bool NOT NULL DEFO true
Indexes
pk_action__id primary key ( id)
fkx_action_type__action ( action_type__id)
fkx_server_type__action ( server_type__id)
Foreign Keys
fk_action_type__action ( action_type__id ) ref action_type ( id )
fk_server_type__action ( server_type__id ) ref server_type ( id )





Table action_type
id serial NOT NULL
name varchar( 64 ) NOT NULL
description varchar( 256 )
active bool NOT NULL DEFO ‘false’
Indexes
pk_action_type__id primary key ( id)





Table action_type__media_type
action_type__id int4 NOT NULL
media_type__id int4 NOT NULL
Indexes
pk_action__media_type primary key ( action_type__id, media_type__id)
fkx_action_type__at_mt ( action_type__id)
fkx_media_type__at_mt ( media_type__id)
Foreign Keys
fk_action_type__at_mt ( action_type__id ) ref action_type ( id )
fk_media_type__at_mt ( media_type__id ) ref media_type ( id )





Table addr
id serial NOT NULL
org__id int4 NOT NULL
type varchar( 64 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_addr__id primary key ( id)
fkx_org__addr ( org__id)
Foreign Keys
fk_org__addr ( org__id ) ref org ( id )





Table addr_part
id serial NOT NULL
addr__id int4 NOT NULL
addr_part_type__id int4 NOT NULL
value varchar( 256 ) NOT NULL
Indexes
pk_addr_part__id primary key ( id)
fkx_addr__addr_part ( addr__id)
fkx_addr_part_type__addr_part ( addr_part_type__id)
Foreign Keys
fk_addr__addr_part ( addr__id ) ref addr ( id )
fk_addr_part_type__addr_part ( addr_part_type__id ) ref addr_part_type ( id )





Table addr_part_type
id serial NOT NULL
name varchar( 64 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_addr_part_type__id primary key ( id)





Table alert
id serial NOT NULL
alert_type__id int4 NOT NULL
event__id int4 NOT NULL
subject varchar( 128 )
message varchar( 512 )
timestamp timestamp NOT NULL DEFO ‘now()’
Indexes
pk_alert__id primary key ( id)
fkx_alert_type__alert ( alert_type__id)
fkx_event__alert ( event__id)
idx_alert__timestamp ( timestamp)
Foreign Keys
fk_alert_type__alert ( alert_type__id ) ref alert_type ( id )
fk_event__alert ( event__id ) ref event ( id )





Table alert_type
id serial NOT NULL
event_type__id int4 NOT NULL
usr__id int4 NOT NULL
name varchar( 64 ) NOT NULL
subject varchar( 128 )
message varchar( 512 )
active bool NOT NULL DEFO ‘true’
del bool NOT NULL DEFO false
Indexes
pk_alert_type__id primary key ( id)
fkx_event_type__alert_type ( event_type__id)
fkx_usr__alert_type ( usr__id)
Foreign Keys
fk_event_type__alert_type ( event_type__id ) ref event_type ( id )
fk_usr__alert_type ( usr__id ) ref usr ( id )





Table alert_type__grp__contact
alert_type__id int4 NOT NULL
contact__id int4 NOT NULL
grp__id int4 NOT NULL
Indexes
pk_alert_type__grp__contact primary key ( alert_type__id, contact__id, grp__id)
fkx_alert_type__grp__contact ( alert_type__id)
fkx_contact__grp__contact ( contact__id)
fkx_grp__grp__contact ( grp__id)
Foreign Keys
fk_alert_type__grp__contact ( alert_type__id ) ref alert_type ( id )
fk_contact__grp__contact ( contact__id ) ref contact ( id )
fk_grp__grp__contact ( grp__id ) ref grp ( id )





Table alert_type__usr__contact
alert_type__id int4 NOT NULL
usr__id int4 NOT NULL
contact__id int4 NOT NULL
Indexes
pk_alert_type__usr__contact primary key ( alert_type__id, usr__id, contact__id)
fkx_alert_type__at_user__cont ( alert_type__id)
fkx_contact__at_usr__contact ( contact__id)
fkx_usr__at_usr__contact ( usr__id)
Foreign Keys
fk_alert_type__at_user__cont ( alert_type__id ) ref alert_type ( id )
fk_contact__at_usr__contact ( contact__id ) ref contact ( id )
fk_usr__at_usr__contact ( usr__id ) ref usr ( id )





Table alert_type_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_alert_type_member__id primary key ( id)
fkx_alert_type__alert_type_member ( object_id)
fkx_member__alert_type_member ( member__id)
Foreign Keys
fk_alert_type__alert_type_member ( object_id ) ref alert_type ( id )
fk_member__alert_type_member ( member__id ) ref member ( id )





Table alert_type_rule
id serial NOT NULL
alert_type__id int4 NOT NULL
attr varchar( 64 ) NOT NULL
operator bpchar NOT NULL
value varchar( 256 ) NOT NULL
Indexes
pk_alert_type_rule__id primary key ( id)
fkx_alert_type__at_rule ( alert_type__id)
Foreign Keys
fk_alert_type__at_rule ( alert_type__id ) ref alert_type ( id )





Table alerted
id serial NOT NULL
usr__id int4 NOT NULL
alert__id int4 NOT NULL
ack_time timestamp
Indexes
pk_alerted__id primary key ( id)
fkx_alert__alerted ( alert__id)
fkx_usr__alerted ( usr__id)
idx_alerted__ack_time ( ack_time)
Foreign Keys
fk_alert__alerted ( alert__id ) ref alert ( id )
fk_usr__alerted ( usr__id ) ref usr ( id )





Table alerted__contact_value
alerted__id int4 NOT NULL
contact__id int4 NOT NULL
contact_value__value varchar( 256 ) NOT NULL
sent_time timestamp
Indexes
pk_alerted__contact_value primary key ( alerted__id, contact__id, contact_value__value)
fkx_alerted__alerted__contact ( alerted__id)
fkx_contact__alerted__cont ( contact__id)
idx_ac_value__cv__value ( contact_value__value)
idx_ac_value__sent_time ( sent_time)
Foreign Keys
fk_alerted__alerted__contact ( alerted__id ) ref alerted ( id )
fk_contact__alerted__cont ( contact__id ) ref contact ( id )





Table at_type
id serial NOT NULL
name varchar( 64 ) NOT NULL
description varchar( 256 )
top_level bool NOT NULL DEFO ‘false’
paginated bool NOT NULL DEFO false
fixed_url bool NOT NULL DEFO false
related_story bool NOT NULL DEFO false
related_media bool NOT NULL DEFO false
media bool NOT NULL DEFO false
biz_class__id int4 NOT NULL
active bool NOT NULL DEFO true
Indexes
pk_at_type__id primary key ( id)
fkx_class__at_type ( biz_class__id)
Foreign Keys
fk_class__at_type ( biz_class__id ) ref class ( id )





Table at_type_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_at_type_member__id primary key ( id)
fkx_at_type__at_type_member ( object_id)
fkx_member__at_type_member ( member__id)
Foreign Keys
fk_at_type__at_type_member ( object_id ) ref at_type ( id )
fk_member__at_type_member ( member__id ) ref member ( id )





Table attr_action
id serial NOT NULL
subsys varchar( 256 ) NOT NULL
name varchar( 256 ) NOT NULL
sql_type varchar( 30 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_action__id primary key ( id)
udx_attr_action__subsys__name unique ( subsys, name)





Table attr_action_meta
id serial NOT NULL
attr__id int4 NOT NULL
name varchar( 256 ) NOT NULL
value varchar( 2048 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_action_meta__id primary key ( id)
udx_attr_action_meta__attr_name unique ( attr__id, name)
fkx_attr_action__attr_action_meta ( attr__id)
Foreign Keys
fk_attr_action__attr_action_meta ( attr__id ) ref attr_action ( id )





Table attr_action_val
id serial NOT NULL
object__id int4 NOT NULL
attr__id int4 NOT NULL
date_val timestamp
short_val varchar( 1024 )
blob_val text
serial bool DEFO ‘false’
active bool NOT NULL DEFO true
Indexes
pk_attr_action_val__id primary key ( id)
udx_attr_action_val__obj_attr unique ( object__id, attr__id)
fkx_action__attr_action_val ( object__id)
fkx_attr_action__attr_action_val ( attr__id)
Foreign Keys
fk_action__attr_action_val ( object__id ) ref action ( id )
fk_attr_action__attr_action_val ( attr__id ) ref attr_action ( id )





Table attr_category
id serial NOT NULL
subsys varchar( 256 ) NOT NULL
name varchar( 256 ) NOT NULL
sql_type varchar( 30 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_category__id primary key ( id)
udx_attr_cat__subsys__name unique ( subsys, name)





Table attr_category_meta
id serial NOT NULL
attr__id int4 NOT NULL
name varchar( 256 ) NOT NULL
value varchar( 2048 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_category_meta__id primary key ( id)
udx_attr_cat_meta__attr_name unique ( attr__id, name)
fkx_attr_cat__attr_cat_meta ( attr__id)
Foreign Keys
fk_attr_cat__attr_cat_meta ( attr__id ) ref attr_category ( id )





Table attr_category_val
id serial NOT NULL
object__id int4 NOT NULL
attr__id int4 NOT NULL
date_val timestamp
short_val varchar( 1024 )
blob_val text
serial bool DEFO ‘false’
active bool NOT NULL DEFO true
Indexes
pk_attr_category_val__id primary key ( id)
udx_attr_cat_val__obj_attr unique ( object__id, attr__id)
fkx_attr_cat__attr_cat_val ( attr__id)
fkx_cat__attr_cat_val ( object__id)
Foreign Keys
fk_attr_cat__attr_cat_val ( attr__id ) ref attr_category ( id )
fk_cat__attr_cat_val ( object__id ) ref category ( id )





Table attr_element_type
id serial NOT NULL
subsys varchar( 256 ) NOT NULL
name varchar( 256 ) NOT NULL
sql_type varchar( 30 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_element_type__id primary key ( id)
udx_attr_et__subsys__name unique ( subsys, name)





Table attr_element_type_meta
id serial NOT NULL
attr__id int4 NOT NULL
name varchar( 256 ) NOT NULL
value varchar( 2048 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_element_type_meta__id primary key ( id)
udx_attr_et_meta__attr_name unique ( attr__id, name)
fkx_attr_et__attr_et_meta ( attr__id)
Foreign Keys
fk_attr_et__attr_et_meta ( attr__id ) ref attr_element_type ( id )





Table attr_element_type_val
id serial NOT NULL
object__id int4 NOT NULL
attr__id int4 NOT NULL
date_val timestamp
short_val varchar( 1024 )
blob_val text
serial bool DEFO ‘false’
active bool NOT NULL DEFO true
Indexes
pk_attr_element_type_val__id primary key ( id)
udx_attr_et_val__obj_attr unique ( object__id, attr__id)
fkx_attr_et__attr_et_val ( attr__id)
fkx_et__attr_et_val ( object__id)
Foreign Keys
fk_attr_et__attr_et_val ( attr__id ) ref attr_element_type ( id )
fk_et__attr_et_val ( object__id ) ref element_type ( id )





Table attr_field_type
id serial NOT NULL
subsys varchar( 256 ) NOT NULL
name varchar( 256 ) NOT NULL
sql_type varchar( 30 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_field_type__id primary key ( id)
udx_attr_field_type__subsys__name unique ( subsys, name)





Table attr_field_type_meta
id serial NOT NULL
attr__id int4 NOT NULL
name varchar( 256 ) NOT NULL
value text
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_field_type_meta__id primary key ( id)
udx_attr_field_type_meta__attr_name unique ( attr__id, name)
fkx_attr_field_type__attr_field_type_meta ( attr__id)
Foreign Keys
fk_attr_field_type__attr_field_type_meta ( attr__id ) ref attr_field_type ( id )





Table attr_field_type_val
id serial NOT NULL
object__id int4 NOT NULL
attr__id int4 NOT NULL
date_val timestamp
short_val varchar( 1024 )
blob_val text
serial bool DEFO ‘false’
active bool NOT NULL DEFO true
Indexes
pk_attr_field_type_val__id primary key ( id)
udx_attr_field_type_val__obj_attr unique ( object__id, attr__id)
fkx_attr_field_type__attr_field_type_val ( attr__id)
fkx_field_type__attr_field_type_val ( object__id)
Foreign Keys
fk_attr_field_type__attr_field_type_val ( attr__id ) ref attr_field_type ( id )
fk_field_type__attr_field_type_val ( object__id ) ref field_type ( id )





Table attr_grp
id serial NOT NULL
subsys varchar( 256 ) NOT NULL
name varchar( 256 ) NOT NULL
sql_type varchar( 30 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_grp__id primary key ( id)
udx_attr_grp__subsys__name unique ( subsys, name)





Table attr_grp_meta
id serial NOT NULL
attr__id int4 NOT NULL
name varchar( 256 ) NOT NULL
value varchar( 2048 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_grp_meta__id primary key ( id)
udx_attr_grp_meta__attr_name unique ( attr__id, name)
fkx_attr_grp__attr_grp_meta ( attr__id)
Foreign Keys
fk_attr_grp__attr_grp_meta ( attr__id ) ref attr_grp ( id )





Table attr_grp_val
id serial NOT NULL
object__id int4 NOT NULL
attr__id int4 NOT NULL
date_val timestamp
short_val varchar( 1024 )
blob_val text
serial bool DEFO ‘false’
active bool NOT NULL DEFO true
Indexes
pk_attr_grp_val__id primary key ( id)
udx_attr_grp_val__obj_attr unique ( object__id, attr__id)
fkx_attr_grp__attr_grp_val ( attr__id)
fkx_grp__attr_grp_val ( object__id)
Foreign Keys
fk_attr_grp__attr_grp_val ( attr__id ) ref attr_grp ( id )
fk_grp__attr_grp_val ( object__id ) ref grp ( id )





Table attr_member
id int4 NOT NULL
subsys varchar( 256 ) NOT NULL
name varchar( 256 ) NOT NULL
sql_type varchar( 30 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_member__id primary key ( id)
udx_attr_member__subsys__name unique ( subsys, name)





Table attr_member_meta
id int4 NOT NULL
attr__id int4 NOT NULL
name varchar( 256 ) NOT NULL
value varchar( 2048 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_attr_member_meta__id primary key ( id)
udx_attr_member_meta__attr_name unique ( attr__id, name)
fkx_attr_member__attr_member_meta ( attr__id)
Foreign Keys
fk_attr_member__attr_member_meta ( attr__id ) ref attr_member ( id )





Table attr_member_val
id int4 NOT NULL
object__id int4 NOT NULL
attr__id int4 NOT NULL
date_val timestamp
short_val varchar( 1024 )
blob_val text
serial bool DEFO ‘false’
active bool NOT NULL DEFO true
Indexes
pk_attr_member_val__id primary key ( id)
udx_attr_member_val__obj_attr unique ( object__id, attr__id)
fkx_attr_member__attr_member_val ( attr__id)
fkx_member__attr_member_val ( object__id)
Foreign Keys
fk_attr_member__attr_member_val ( attr__id ) ref attr_member ( id )
fk_member__attr_member_val ( object__id ) ref member ( id )





Table category
id serial NOT NULL
site__id int4 NOT NULL
directory varchar( 128 ) NOT NULL
uri varchar( 256 ) NOT NULL
name varchar( 128 )
description varchar( 256 )
parent_id int4 NOT NULL
asset_grp_id int4 NOT NULL
active bool NOT NULL DEFO true
Indexes
pk_category__id primary key ( id)
udx_category__site_uri unique ( site__id, uri)
fkx_asset_grp__category ( asset_grp_id)
fkx_category__site ( site__id)
idx_category__parent_id ( parent_id)
idx_category__uri ( uri)
Foreign Keys
fk_asset_grp__category ( asset_grp_id ) ref grp ( id )
fk_category__site ( site__id ) ref site ( id )





Table category_keyword
category_id int4 NOT NULL
keyword_id int4 NOT NULL
Indexes
pk_category_keyword primary key ( category_id, keyword_id)
fkx_category__category_keyword ( category_id)
fkx_keyword__category_keyword ( keyword_id)
Foreign Keys
fk_category__category_keyword ( category_id ) ref category ( id )
fk_keyword__category_keyword ( keyword_id ) ref keyword ( id )





Table category_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_category_member__id primary key ( id)
fkx_category__category_member ( object_id)
fkx_member__category_member ( member__id)
Foreign Keys
fk_category__category_member ( object_id ) ref category ( id )
fk_member__category_member ( member__id ) ref member ( id )





Table class
id serial NOT NULL
key_name varchar( 32 ) NOT NULL
pkg_name varchar( 128 ) NOT NULL
disp_name varchar( 128 ) NOT NULL
plural_name varchar( 128 ) NOT NULL
description varchar( 256 )
distributor bool NOT NULL DEFO ‘false’
Indexes
pk_class__id primary key ( id)





Table contact
id serial NOT NULL
type varchar( 64 ) NOT NULL
description varchar( 256 )
active bool NOT NULL DEFO ‘true’
alertable bool NOT NULL DEFO false
Indexes
pk_contact__id primary key ( id)





Table contact_value
id serial NOT NULL
contact__id int4 NOT NULL
value varchar( 256 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_contact_value__id primary key ( id)
fkx_contact__contact_value ( contact__id)
Foreign Keys
fk_contact__contact_value ( contact__id ) ref contact ( id )





Table contrib_type_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_contrib_type_member__id primary key ( id)
fkx_contrib_type__ctype_member ( object_id)
fkx_member__ctype_member ( member__id)
Foreign Keys
fk_contrib_type__ctype_member ( object_id ) ref grp ( id )
fk_member__ctype_member ( member__id ) ref member ( id )





Table desk
id serial NOT NULL
name varchar( 64 ) NOT NULL
description varchar( 256 )
pre_chk_rules int4
post_chk_rules int4
asset_grp int4
publish bool NOT NULL DEFO false
active bool NOT NULL DEFO true
Indexes
pk_desk__id primary key ( id)
fkx_asset_grp__desk ( asset_grp)
fkx_post_grp__desk ( post_chk_rules)
fkx_pre_grp__desk ( pre_chk_rules)
Foreign Keys
fk_pre_grp__desk ( pre_chk_rules ) ref grp ( id )
fk_post_grp__desk ( post_chk_rules ) ref grp ( id )
fk_asset_grp__desk ( asset_grp ) ref grp ( id )





Table desk_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_desk_member__id primary key ( id)
fkx_desk__desk_member ( object_id)
fkx_member__desk_member ( member__id)
Foreign Keys
fk_desk__desk_member ( object_id ) ref desk ( id )
fk_member__desk_member ( member__id ) ref member ( id )





Table dest_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_dest_member__id primary key ( id)
fkx_dest__dest_member ( object_id)
fkx_member__dest_member ( member__id)
Foreign Keys
fk_member__dest_member ( member__id ) ref member ( id )
fk_dest__dest_member ( object_id ) ref server_type ( id )





Table element_type
id serial NOT NULL
name varchar( 64 ) NOT NULL
key_name varchar( 64 ) NOT NULL
description varchar( 256 )
top_level bool NOT NULL DEFO ‘false’
paginated bool NOT NULL DEFO false
fixed_uri bool NOT NULL DEFO false
related_story bool NOT NULL DEFO false
related_media bool NOT NULL DEFO false
displayed bool NOT NULL DEFO false
media bool NOT NULL DEFO false
biz_class__id int4 NOT NULL
type__id int4
active bool NOT NULL DEFO true
Indexes
pk_element_type__id primary key ( id)
fkx_class__element_type ( biz_class__id)
fkx_et_type__element_type ( type__id)
Foreign Keys
fk_at_type__element ( type__id ) ref at_type ( id )
fk_class__element_type ( biz_class__id ) ref class ( id )





Table element_type__output_channel
id serial NOT NULL
element_type__id int4 NOT NULL
output_channel__id int4 NOT NULL
enabled bool NOT NULL DEFO true
active bool NOT NULL DEFO true
Indexes
pk_element_type__output_channel__id primary key ( id)
udx_et_oc_id__et__oc_id unique ( element_type__id, output_channel__id)
fkx_element__et_oc ( element_type__id)
fkx_output_channel__et_oc ( output_channel__id)
Foreign Keys
fk_element_type__et_oc ( element_type__id ) ref element_type ( id )
fk_output_channel__et_oc ( output_channel__id ) ref output_channel ( id )





Table element_type__site
id serial NOT NULL
element_type__id int4 NOT NULL
site__id int4 NOT NULL
active bool NOT NULL DEFO true
primary_oc__id int4 NOT NULL
Indexes
pk_element_type__site__id primary key ( id)
udx_element_type__site unique ( element_type__id, site__id)
fkx_et__et__site__element_type__id ( element_type__id)
fkx_output_channel__et__site ( primary_oc__id)
fkx_site__et__site__site__id ( site__id)
Foreign Keys
fk_element_type__et__site__et__id ( element_type__id ) ref element_type ( id )
fk_output_channel__et__site ( primary_oc__id ) ref output_channel ( id )
fk_site__et__site__site__id ( site__id ) ref site ( id )





Table element_type_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_element_type_member__id primary key ( id)
fkx_element_type__et_member ( object_id)
fkx_member__et_member ( member__id)
Foreign Keys
fk_element__et_member ( object_id ) ref element_type ( id )
fk_member__et_member ( member__id ) ref member ( id )





Table event
id serial NOT NULL
event_type__id int4 NOT NULL
usr__id int4 NOT NULL
obj_id int4 NOT NULL
timestamp timestamp NOT NULL DEFO (timeofday())::timestamp with time zone
Indexes
pk_event__id primary key ( id)
fkx_event_type__event ( event_type__id)
fkx_usr__event ( usr__id)
idx_event__obj_id ( obj_id)
idx_event__timestamp ( timestamp)
Foreign Keys
fk_event_type__event ( event_type__id ) ref event_type ( id )
fk_usr__event ( usr__id ) ref usr ( id )





Table event_attr
id serial NOT NULL
event__id int4 NOT NULL
event_type_attr__id int4 NOT NULL
value varchar( 128 )
Indexes
pk_event_attr__id primary key ( id)
fkx_event__event_attr ( event__id)
fkx_event_type_attr__event_attr ( event_type_attr__id)
Foreign Keys
fk_event__event_attr ( event__id ) ref event ( id )
fk_event_type_attr__event_attr ( event_type_attr__id ) ref event_type_attr ( id )





Table event_type
id serial NOT NULL
key_name varchar( 64 ) NOT NULL
name varchar( 64 ) NOT NULL
description varchar( 256 ) NOT NULL
class__id int4 NOT NULL
active bool NOT NULL DEFO true
Indexes
pk_event_type__id primary key ( id)
udx_event_type__class_id__name unique ( class__id, name)
fkx_class__event_type ( class__id)
Foreign Keys
fk_class__event_type ( class__id ) ref class ( id )





Table event_type_attr
id serial NOT NULL
event_type__id int4 NOT NULL
name varchar( 64 ) NOT NULL
Indexes
pk_event_type_attr__id primary key ( id)
fkx_event_type__event_type_attr ( event_type__id)
Foreign Keys
fk_event_type__event_type_attr ( event_type__id ) ref event_type ( id )





Table field_type
id serial NOT NULL
element_type__id int4 NOT NULL
name text NOT NULL
key_name text NOT NULL
description text
place int4 NOT NULL
min_occurrence int4 NOT NULL DEFO 0
max_occurrence int4 NOT NULL DEFO 0
autopopulated bool NOT NULL DEFO false
max_length int4 NOT NULL DEFO 0
sql_type varchar( 30 ) NOT NULL DEFO ‘short’::character varying
widget_type varchar( 30 ) NOT NULL DEFO ‘’text’::character varying’
precision int2
cols int4 NOT NULL
rows int4 NOT NULL
length int4 NOT NULL
vals text
multiple bool NOT NULL DEFO ‘false’
default_val text
active bool NOT NULL DEFO ‘true’
Indexes
pk_field_type__id primary key ( id)
fkx_element_type__field_type ( element_type__id)
Foreign Keys
fk_element_type__field_type ( element_type__id ) ref element_type ( id )





Table grp
id serial NOT NULL
parent_id int4
class__id int4 NOT NULL
name varchar( 64 )
description varchar( 256 )
secret bool NOT NULL DEFO ‘true’
permanent bool NOT NULL DEFO false
active bool NOT NULL DEFO true
Indexes
pk_grp__id primary key ( id)
fkx_class__grp ( class__id)
fkx_grp__grp ( parent_id)
Foreign Keys
fk_class__grp ( class__id ) ref class ( id )
fk_grp__grp ( parent_id ) ref grp ( id )





Table grp_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_grp_member__id primary key ( id)
fkx_grp__grp_member ( object_id)
fkx_member__grp_member ( member__id)
Foreign Keys
fk_grp__grp_member ( object_id ) ref grp ( id )
fk_member__grp_member ( member__id ) ref member ( id )





Table grp_priv
id serial NOT NULL
grp__id int4 NOT NULL
value int2 NOT NULL
mtime timestamp NOT NULL DEFO now()
Indexes
pk_grp_priv__id primary key ( id)
fkx_grp__grp_priv ( grp__id)
Foreign Keys
fk_grp__grp_priv ( grp__id ) ref grp ( id )





Table grp_priv__grp_member
grp_priv__id int4 NOT NULL
grp__id int4 NOT NULL
Indexes
pk_grp_priv__grp_member primary key ( grp_priv__id, grp__id)
fkx_grp__grp_priv__grp_member ( grp__id)
fkx_grp_priv__grp_priv__grp_member ( grp_priv__id)
Foreign Keys
fk_grp__grp_priv__grp_member ( grp__id ) ref grp ( id )
fk_grp_priv__grp_priv__grp_mem ( grp_priv__id ) ref grp_priv ( id )





Table job
id serial NOT NULL
name text NOT NULL
usr__id int4 NOT NULL
sched_time timestamp NOT NULL DEFO now()
priority int2 NOT NULL DEFO 3
comp_time timestamp
expire bool NOT NULL DEFO false
failed bool NOT NULL DEFO false
tries int2 NOT NULL DEFO 0
executing bool NOT NULL DEFO false
class__id int4 NOT NULL
story_instance__id int4
media_instance__id int4
error_message text
Indexes
pk_job__id primary key ( id)
fkx_media_instance__job ( media_instance__id)
fkx_story_instance__job ( story_instance__id)
fkx_usr__job ( usr__id)
idx_job__executing ( executing)
idx_job__sched_time ( sched_time)
Foreign Keys
fk_job__class ( class__id ) ref class ( id )
fk_job__media_instance ( media_instance__id ) ref media_instance ( id )
fk_job__story_instance ( story_instance__id ) ref story_instance ( id )
fk_job__usr ( usr__id ) ref usr ( id )





Table job__resource
job__id int4 NOT NULL
resource__id int4 NOT NULL
Indexes
pk_job__resource primary key ( job__id, resource__id)
fkx_job__job__resource ( job__id)
fkx_resource__job__resource ( resource__id)
Foreign Keys
fk_job__job__resource ( job__id ) ref job ( id )
fk_resource__job__resource ( resource__id ) ref resource ( id )





Table job__server_type
job__id int4 NOT NULL
server_type__id int4 NOT NULL
Indexes
pk_job__server_type primary key ( job__id, server_type__id)
fkx_job__job__server_type ( job__id)
fkx_srvr_type__job__srvr_type ( server_type__id)
Foreign Keys
fk_job__job__server_type ( job__id ) ref job ( id )
fk_srvr_type__job__srvr_type ( server_type__id ) ref server_type ( id )





Table job_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_job_member__id primary key ( id)
fkx_job__job_member ( object_id)
fkx_member__job_member ( member__id)
Foreign Keys
fk_job__job_member ( object_id ) ref job ( id )
fk_member__job_member ( member__id ) ref member ( id )





Table keyword
id serial NOT NULL
name varchar( 256 ) NOT NULL
screen_name varchar( 256 ) NOT NULL
sort_name varchar( 256 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_keyword__id primary key ( id)





Table keyword_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_keyword_member__id primary key ( id)
fkx_keyword__keyword_member ( object_id)
fkx_member__keyword_member ( member__id)
Foreign Keys
fk_keyword__keyword_member ( object_id ) ref keyword ( id )
fk_member__keyword_member ( member__id ) ref member ( id )





Table media
id serial NOT NULL
uuid text NOT NULL
element_type__id int4 NOT NULL
priority int2 NOT NULL DEFO 3
source__id int4 NOT NULL
current_version int4
published_version int4
usr__id int4
first_publish_date timestamp
publish_date timestamp
expire_date timestamp
workflow__id int4 NOT NULL
desk__id int4 NOT NULL
publish_status bool NOT NULL DEFO false
active bool NOT NULL DEFO true
site__id int4 NOT NULL
alias_id int4
Indexes
pk_media__id primary key ( id)
fkx_alias_id__media ( alias_id)
fkx_element_type__media ( element_type__id)
fkx_media__desk__id ( desk__id)
fkx_media__workflow__id ( workflow__id)
fkx_site_id__media ( site__id)
fkx_source__media ( source__id)
fkx_usr__media ( usr__id)
idx_media__first_publish_date ( first_publish_date)
idx_media__publish_date ( publish_date)
idx_media__uuid ( uuid)
Foreign Keys
fk_desk__media ( desk__id ) ref desk ( id )
fk_element_type__media ( element_type__id ) ref element_type ( id )
fk_media__media_id ( alias_id ) ref media ( id )
fk_site__media ( site__id ) ref site ( id )
fk_source__media ( source__id ) ref source ( id )
fk_usr__media ( usr__id ) ref usr ( id )
fk_workflow__media ( workflow__id ) ref workflow ( id )





Table media__contributor
id serial NOT NULL
media_instance__id int4 NOT NULL
member__id int4 NOT NULL
place int2 NOT NULL
role varchar( 256 )
Indexes
pk_media_category_id primary key ( id)
fkx_media__media__contributor ( media_instance__id)
fkx_member__media__contributor ( member__id)
Foreign Keys
fk_media__media__contributor ( media_instance__id ) ref media_instance ( id )
fk_member__media__contributor ( member__id ) ref member ( id )





Table media__output_channel
media_instance__id int4 NOT NULL
output_channel__id int4 NOT NULL
Indexes
pk_media_output_channel primary key ( media_instance__id, output_channel__id)
fkx_media__oc__media ( media_instance__id)
fkx_media__oc__oc ( output_channel__id)
Foreign Keys
fk_media__oc__media ( media_instance__id ) ref media_instance ( id )
fk_media__oc__oc ( output_channel__id ) ref output_channel ( id )





Table media__resource
media__id int4 NOT NULL
resource__id int4 NOT NULL
Indexes
pk_media__resource primary key ( media__id, resource__id)
fkx_media__media__resource ( media__id)
fkx_resource__media__resource ( resource__id)
Foreign Keys
fk_media__media__resource ( media__id ) ref media ( id )
fk_resource__media__resource ( resource__id ) ref resource ( id )





Table media_element
id serial NOT NULL
element_type__id int4 NOT NULL
object_instance_id int4 NOT NULL
parent_id int4
place int4 NOT NULL
object_order int4 NOT NULL
displayed bool NOT NULL DEFO false
related_story__id int4
related_media__id int4
active bool NOT NULL DEFO true
Indexes
pk_media_element__id primary key ( id)
fkx_media__media_element ( object_instance_id)
fkx_media_element__element_type ( element_type__id)
fkx_media_element__media_element ( parent_id)
fkx_media_element__related_media ( related_media__id)
fkx_media_element__related_story ( related_story__id)
Foreign Keys
fk_media_element__element_type ( element_type__id ) ref element_type ( id )
fk_media_element__related_media ( related_media__id ) ref media ( id )
fk_media_element__media_element ( parent_id ) ref media_element ( id )
fk_media__media_element ( object_instance_id ) ref media_instance ( id )
fk_media_element__related_story ( related_story__id ) ref story ( id )





Table media_field
id serial NOT NULL
field_type__id int4 NOT NULL
object_instance_id int4 NOT NULL
parent_id int4 NOT NULL
place int4 NOT NULL
hold_val bool NOT NULL DEFO false
object_order int4 NOT NULL
date_val timestamp
short_val varchar( 1024 )
blob_val text
active bool NOT NULL DEFO ‘true’
Indexes
pk_media_field__id primary key ( id)
fkx_field_type__media_field ( field_type__id)
fkx_media_field__media_field ( parent_id)
fkx_media_instance__media_field ( object_instance_id)
Foreign Keys
fk_field_type__media_field ( field_type__id ) ref field_type ( id )
fk_media_element__media_field ( parent_id ) ref media_element ( id )
fk_media_instance__media_field ( object_instance_id ) ref media_instance ( id )





Table media_fields
id serial NOT NULL
biz_pkg int4 NOT NULL
name varchar( 32 ) NOT NULL
function_name varchar( 256 ) NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_media_fields__id primary key ( id)





Table media_instance
id serial NOT NULL
name varchar( 256 )
description varchar( 1024 )
media__id int4 NOT NULL
usr__id int4 NOT NULL
version int4
category__id int4 NOT NULL
media_type__id int4 NOT NULL
primary_oc__id int4 NOT NULL
file_size int4
file_name varchar( 256 )
location varchar( 256 )
uri varchar( 256 )
cover_date timestamp NOT NULL DEFO ‘now()’
note text
checked_out bool NOT NULL DEFO ‘false’
Indexes
pk_media_instance__id primary key ( id)
udx_media__media_instance unique ( media__id, version, checked_out)
fkx_category__media_instance ( category__id)
fkx_media_type__media_instance ( media_type__id)
fkx_primary_oc__media_instance ( primary_oc__id)
fkx_usr__media_instance ( usr__id)
idx_media_instance__cover_date ( cover_date)
idx_media_instance__note ( note)
Foreign Keys
fk_category__media_instance ( category__id ) ref category ( id )
fk_media__media_instance ( media__id ) ref media ( id )
fk_media_type__media_instance ( media_type__id ) ref media_type ( id )
fk_primary_oc__media_instance ( primary_oc__id ) ref output_channel ( id )
fk_usr__media_instance ( usr__id ) ref usr ( id )





Table media_keyword
media_id int4 NOT NULL
keyword_id int4 NOT NULL
Indexes
pk_media_keyword primary key ( media_id, keyword_id)
fkx_keyword__media_keyword ( keyword_id)
fkx_media__media_keyword ( media_id)
Foreign Keys
fk_keyword__media_keyword ( keyword_id ) ref keyword ( id )
fk_media__media_keyword ( media_id ) ref media ( id )





Table media_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_media_member__id primary key ( id)
fkx_media__media_member ( object_id)
fkx_member__media_member ( member__id)
Foreign Keys
fk_media__media_member ( object_id ) ref media ( id )
fk_member__media_member ( member__id ) ref member ( id )





Table media_type
id serial NOT NULL
name varchar( 128 ) NOT NULL
description varchar( 256 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_media_type__id primary key ( id)





Table media_type_ext
id serial NOT NULL
media_type__id int4 NOT NULL
extension varchar( 10 ) NOT NULL
Indexes
pk_media_type_ext__id primary key ( id)
fkx_media_type__media_type_ext ( media_type__id)
Foreign Keys
fk_media_type__media_type_ext ( media_type__id ) ref media_type ( id )





Table media_type_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_media_type_member__id primary key ( id)
fkx_media_type__media_type_member ( object_id)
fkx_member__media_type_member ( member__id)
Foreign Keys
fk_media_type__media_type_member ( object_id ) ref media_type ( id )
fk_member__media_type_member ( member__id ) ref member ( id )





Table media_uri
id serial NOT NULL
media__id int4 NOT NULL
site__id int4 NOT NULL
uri text NOT NULL
Indexes
pk_media_uri__id primary key ( id)
fkx_media__media_uri ( media__id)
Foreign Keys
fk_media__media_uri ( media__id ) ref media ( id )
fk_media__site__id ( site__id ) ref site ( id )





Table member
id serial NOT NULL
grp__id int4 NOT NULL
class__id int4 NOT NULL
active bool NOT NULL DEFO true
Indexes
pk_member__id primary key ( id)
fkx_grp__class ( class__id)
fkx_grp__member ( grp__id)
Foreign Keys
fk_class__member ( class__id ) ref class ( id )
fk_grp__member ( grp__id ) ref grp ( id )





Table org
id serial NOT NULL
name varchar( 64 ) NOT NULL
long_name varchar( 128 )
personal bool NOT NULL DEFO ‘false’
active bool NOT NULL DEFO true
Indexes
pk_org__id primary key ( id)





Table org_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_org_member__id primary key ( id)
fkx_member__org_member ( member__id)
fkx_org__org_member ( object_id)
Foreign Keys
fk_member__org_member ( member__id ) ref member ( id )
fk_org__org_member ( object_id ) ref org ( id )





Table output_channel
id serial NOT NULL
name varchar( 64 ) NOT NULL
description varchar( 256 )
site__id int4 NOT NULL
protocol varchar( 16 )
filename varchar( 32 ) NOT NULL
file_ext varchar( 32 )
primary_ce bool
uri_format varchar( 64 ) NOT NULL
fixed_uri_format varchar( 64 ) NOT NULL
uri_case int2 NOT NULL DEFO ‘1’
use_slug bool NOT NULL DEFO false
burner int2 NOT NULL DEFO 1
active bool NOT NULL DEFO true
Indexes
pk_output_channel__id primary key ( id)
fkx_site__output_channel ( site__id)
Foreign Keys
fk_site__output_channel ( site__id ) ref site ( id )





Table output_channel_include
id serial NOT NULL
output_channel__id int4 NOT NULL
include_oc_id int4 NOT NULL
Indexes
pk_output_channel_include__id primary key ( id)
udx_output_channel_include unique ( output_channel__id, include_oc_id)
fkx_oc__oc_include_inc ( include_oc_id)
fkx_output_channel__oc_include ( output_channel__id)
Foreign Keys
fk_output_channel__oc_include ( output_channel__id ) ref output_channel ( id )
fk_oc__oc_include_inc ( include_oc_id ) ref output_channel ( id )





Table output_channel_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_output_channel_member__id primary key ( id)
fkx_member__oc_member ( member__id)
fkx_output_channel__oc_member ( object_id)
Foreign Keys
fk_member__oc_member ( member__id ) ref member ( id )
fk_output_channel__oc_member ( object_id ) ref output_channel ( id )





Table person
id serial NOT NULL
prefix varchar( 32 )
lname varchar( 64 )
fname varchar( 64 )
mname varchar( 64 )
suffix varchar( 32 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_person__id primary key ( id)





Table person__contact_value
person__id int4 NOT NULL
contact_value__id int4 NOT NULL
Indexes
pk_person__contact_value primary key ( person__id, contact_value__id)
fkx_contact_value__p_c_val ( contact_value__id)
fkx_person__p_c_val ( person__id)
Foreign Keys
fk_contact_value__p_c_val ( contact_value__id ) ref contact_value ( id )
fk_person__p_c_val ( person__id ) ref person ( id )





Table person_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_person_member__id primary key ( id)
fkx_member__person_member ( member__id)
fkx_person__person_member ( object_id)
Foreign Keys
fk_member__person_member ( member__id ) ref member ( id )
fk_person__person_member ( object_id ) ref person ( id )





Table person_org
id serial NOT NULL
person__id int4 NOT NULL
org__id int4 NOT NULL
role varchar( 64 )
department varchar( 64 )
title varchar( 64 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_person_org__id primary key ( id)
udx_person_org__person__org unique ( person__id, org__id, role)
fkx_org__person_org ( org__id)
fkx_person__person_org ( person__id)
Foreign Keys
fk_org__person_org ( org__id ) ref org ( id )
fk_person__person_org ( person__id ) ref person ( id )





Table person_org__addr
addr__id int4 NOT NULL
person_org__id int4 NOT NULL
Indexes
pk_person_org__addr__all primary key ( addr__id, person_org__id)
fk_person_org__pers_org_addr ( person_org__id)
fkx_addr__person_org_addr ( addr__id)
Foreign Keys
fk_addr__person_org_addr ( addr__id ) ref addr ( id )
fk_person_org__pers_org_addr ( person_org__id ) ref person_org ( id )





Table pref
id serial NOT NULL
name varchar( 64 ) NOT NULL
description varchar( 256 )
value varchar( 256 )
def varchar( 256 )
manual bool NOT NULL DEFO ‘false’
opt_type varchar( 16 ) NOT NULL
can_be_overridden bool NOT NULL DEFO ‘false’
Indexes
pk_pref__id primary key ( id)





Table pref_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_pref_member__id primary key ( id)
fkx_member__pref_member ( member__id)
fkx_pref__pref_member ( object_id)
Foreign Keys
fk_member__pref_member ( member__id ) ref member ( id )
fk_pref__pref_member ( object_id ) ref pref ( id )





Table pref_opt
pref__id int4 NOT NULL
value varchar( 256 ) NOT NULL
description varchar( 256 )
Indexes
pk_pref_opt__pref__id__value primary key ( pref__id, value)
fkx_pref__pref__opt ( pref__id)
Foreign Keys
fk_pref__pref_opt ( pref__id ) ref pref ( id )





Table resource
id serial NOT NULL
parent_id int4
media_type__id int4 NOT NULL
path varchar( 256 ) NOT NULL
uri varchar( 256 ) NOT NULL
size int4 NOT NULL
mod_time timestamp NOT NULL
is_dir bool NOT NULL
Indexes
pk_resource__id primary key ( id)
udx_resource__path__uri unique ( path, uri)
fkx_media_type__resource ( media_type__id)
fkx_resource__resource ( parent_id)
idx_resource__mod_time ( mod_time)
idx_resource__path ( path)
idx_resource__uri ( uri)
Foreign Keys
fk_media_type__resource ( media_type__id ) ref media_type ( id )
fk_resource__resource ( parent_id ) ref resource ( id )





Table server
id serial NOT NULL
server_type__id int4 NOT NULL
host_name varchar( 128 ) NOT NULL
os bpchar NOT NULL
doc_root varchar( 128 ) NOT NULL
login varchar( 64 )
password varchar( 64 )
cookie varchar( 512 )
active bool NOT NULL DEFO ‘true’
Indexes
pk_server__id primary key ( id)
udx_server__name__st_id unique ( host_name, server_type__id)
fkx_server_type__server ( server_type__id)
idx_server__os ( os)
Foreign Keys
fk_server_type__server ( server_type__id ) ref server_type ( id )





Table server_type
id serial NOT NULL
class__id int4 NOT NULL
name varchar( 64 ) NOT NULL
description varchar( 256 )
site__id int4 NOT NULL
copyable bool NOT NULL DEFO false
publish bool NOT NULL DEFO true
preview bool NOT NULL DEFO false
active bool NOT NULL DEFO true
Indexes
pk_server_type__id primary key ( id)
fkx_class__server_type ( class__id)
fkx_site__server_type ( site__id)
Foreign Keys
fk_class__server_type ( class__id ) ref class ( id )
fk_site__server_type ( site__id ) ref site ( id )





Table server_type__output_channel
server_type__id int4 NOT NULL
output_channel__id int4 NOT NULL
Indexes
pk_server_type__output_channel primary key ( server_type__id, output_channel__id)
fk_output_channel__st_oc ( output_channel__id)
fkx_server_type__st_oc ( server_type__id)
Foreign Keys
fk_output_channel__st_oc ( output_channel__id ) ref output_channel ( id )
fk_server_type__st_oc ( server_type__id ) ref server_type ( id )





Table site
id int4 NOT NULL
name text
description text
domain_name text
active bool NOT NULL DEFO ‘true’
Indexes
pk_site__id primary key ( id)
Foreign Keys
fk_grp__site ( id ) ref grp ( id )





Table site_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_site_member__id primary key ( id)
fkx_member__site_member ( member__id)
fkx_site__site_member ( object_id)
Foreign Keys
fk_member__site_member ( member__id ) ref member ( id )
fk_site__site_member ( object_id ) ref site ( id )





Table source
id serial NOT NULL
org__id int4 NOT NULL
name varchar( 64 ) NOT NULL
description varchar( 256 )
expire int2 NOT NULL DEFO ‘0’
active bool DEFO true
Indexes
pk_source__id primary key ( id)
udx_source_name unique ( name)
fkx_source__org ( org__id)
Foreign Keys
fk_org__source ( org__id ) ref org ( id )





Table source_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_source_member__id primary key ( id)
fkx_member__source_member ( member__id)
fkx_source__source_member ( object_id)
Foreign Keys
fk_member__source_member ( member__id ) ref member ( id )
fk_source__source_member ( object_id ) ref source ( id )





Table story
id serial NOT NULL
uuid text NOT NULL
priority int2 NOT NULL DEFO ‘3’
source__id int4 NOT NULL
usr__id int4
element_type__id int4 NOT NULL
primary_uri varchar( 128 )
first_publish_date timestamp
publish_date timestamp
expire_date timestamp
current_version int4 NOT NULL
published_version int4
workflow__id int4 NOT NULL
desk__id int4 NOT NULL
publish_status bool NOT NULL DEFO false
active bool NOT NULL DEFO true
site__id int4 NOT NULL
alias_id int4
Indexes
pk_story__id primary key ( id)
fkx_alias_id__story ( alias_id)
fkx_element_type__story ( element_type__id)
fkx_site_id__story ( site__id)
fkx_source__story ( source__id)
fkx_story__desk__id ( desk__id)
fkx_story__workflow__id ( workflow__id)
fkx_usr__story ( usr__id)
idx_story__first_publish_date ( first_publish_date)
idx_story__publish_date ( publish_date)
idx_story__uuid ( uuid)
Foreign Keys
fk_desk__story ( desk__id ) ref desk ( id )
fk_element_type__story ( element_type__id ) ref element_type ( id )
fk_site__story ( site__id ) ref site ( id )
fk_source__story ( source__id ) ref source ( id )
fk_story__story_id ( alias_id ) ref story ( id )
fk_usr__story ( usr__id ) ref usr ( id )
fk_workflow__story ( workflow__id ) ref workflow ( id )





Table story__category
id serial NOT NULL
story_instance__id int4 NOT NULL
category__id int4 NOT NULL
main bool NOT NULL DEFO false
Indexes
pk_story_category__id primary key ( id)
udx_story_category__story__cat unique ( story_instance__id, category__id)
fkx_category__story__category ( category__id)
fkx_story__story__category ( story_instance__id)
Foreign Keys
fk_category__story__category ( category__id ) ref category ( id )
fk_story__story__category ( story_instance__id ) ref story_instance ( id )





Table story__contributor
id serial NOT NULL
story_instance__id int4 NOT NULL
member__id int4 NOT NULL
place int2 NOT NULL
role varchar( 256 )
Indexes
pk_story_category_id primary key ( id)
fkx_member__story__contributor ( member__id)
fkx_story__story__contributor ( story_instance__id)
Foreign Keys
fk_member__story__contributor ( member__id ) ref member ( id )
fk_story__story__contributor ( story_instance__id ) ref story_instance ( id )





Table story__output_channel
story_instance__id int4 NOT NULL
output_channel__id int4 NOT NULL
Indexes
pk_story_output_channel primary key ( story_instance__id, output_channel__id)
fkx_story__oc__oc ( output_channel__id)
fkx_story__oc__story ( story_instance__id)
Foreign Keys
fk_story__oc__oc ( output_channel__id ) ref output_channel ( id )
fk_story__oc__story ( story_instance__id ) ref story_instance ( id )





Table story__resource
story__id int4 NOT NULL
resource__id int4 NOT NULL
Indexes
pk_story__resource primary key ( story__id, resource__id)
fkx_resource__story__resource ( resource__id)
fkx_story__story__resource ( story__id)
Foreign Keys
fk_resource__story__resource ( resource__id ) ref resource ( id )
fk_story__story__resource ( story__id ) ref story ( id )





Table story_element
id serial NOT NULL
element_type__id int4 NOT NULL
object_instance_id int4 NOT NULL
parent_id int4
place int4 NOT NULL
object_order int4 NOT NULL
displayed bool NOT NULL DEFO false
related_story__id int4
related_media__id int4
active bool NOT NULL DEFO true
Indexes
pk_story_element__id primary key ( id)
fkx_story__story_element ( object_instance_id)
fkx_story_element__element_type ( element_type__id)
fkx_story_element__related_media ( related_media__id)
fkx_story_element__related_story ( related_story__id)
fkx_story_element__story_element ( parent_id)
Foreign Keys
fk_story_element__element_type ( element_type__id ) ref element_type ( id )
fk_story_element__related_media ( related_media__id ) ref media ( id )
fk_story_element__related_story ( related_story__id ) ref story ( id )
fk_story_element__story_element ( parent_id ) ref story_element ( id )
fk_story__story_element ( object_instance_id ) ref story_instance ( id )





Table story_field
id serial NOT NULL
field_type__id int4 NOT NULL
object_instance_id int4 NOT NULL
parent_id int4 NOT NULL
hold_val bool NOT NULL DEFO false
place int4 NOT NULL
object_order int4 NOT NULL
date_val timestamp
short_val text
blob_val text
active bool NOT NULL DEFO ‘true’
Indexes
pk_story_field__id primary key ( id)
fkx_field_type__story_field ( field_type__id)
fkx_story_field__story_field ( parent_id)
fkx_story_instance__story_field ( object_instance_id)
Foreign Keys
fk_field_type__story_field ( field_type__id ) ref field_type ( id )
fk_story_element__story_field ( parent_id ) ref story_element ( id )
fk_story_instance__story_field ( object_instance_id ) ref story_instance ( id )





Table story_instance
id serial NOT NULL
name varchar( 256 )
description varchar( 1024 )
story__id int4 NOT NULL
version int4
usr__id int4 NOT NULL
slug varchar( 64 )
primary_oc__id int4 NOT NULL
cover_date timestamp NOT NULL DEFO now()
note text
checked_out bool NOT NULL DEFO ‘false’
Indexes
pk_story_instance__id primary key ( id)
udx_story__story_instance unique ( story__id, version, checked_out)
fkx_primary_oc__story_instance ( primary_oc__id)
fkx_usr__story_instance ( usr__id)
idx_story_instance__cover_date ( cover_date)
idx_story_instance__note ( note)
Foreign Keys
fk_primary_oc__story_instance ( primary_oc__id ) ref output_channel ( id )
fk_story__story_instance ( story__id ) ref story ( id )
fk_usr__story_instance ( usr__id ) ref usr ( id )





Table story_keyword
story_id int4 NOT NULL
keyword_id int4 NOT NULL
Indexes
pk_story_keyword primary key ( story_id, keyword_id)
fkx_keyword__story_keyword ( keyword_id)
fkx_story__story_keyword ( story_id)
Foreign Keys
fk_keyword__story_keyword ( keyword_id ) ref keyword ( id )
fk_story__story_keyword ( story_id ) ref story ( id )





Table story_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_story_member__id primary key ( id)
fkx_member__story_member ( member__id)
fkx_story__story_member ( object_id)
Foreign Keys
fk_member__story_member ( member__id ) ref member ( id )
fk_story__story_member ( object_id ) ref story ( id )





Table story_uri
id serial NOT NULL
story__id int4 NOT NULL
site__id int4 NOT NULL
uri text NOT NULL
Indexes
pk_story_uri__id primary key ( id)
fkx_story__story_uri ( story__id)
Foreign Keys
fk_story__site__id ( site__id ) ref site ( id )
fk_story__story_uri ( story__id ) ref story ( id )





Table subelement_type
id serial NOT NULL
parent_id int4 NOT NULL
child_id int4 NOT NULL
place int4 NOT NULL DEFO 1
min_occurrence int4 NOT NULL DEFO 0
max_occurrence int4 NOT NULL DEFO 0
Indexes
pk_subelement_type__id primary key ( id)
udx_subelement_type__parent__child unique ( parent_id, child_id)
fkx_element_type__subelement__child_id ( child_id)
fkx_element_type__subelement__parent_id ( parent_id)
Foreign Keys
fkx_element_type__subelement__parent_id ( parent_id ) ref element_type ( id )
fkx_element_type__subelement__child_id ( child_id ) ref element_type ( id )





Table template
id serial NOT NULL
name varchar( 256 )
description varchar( 1024 )
priority int2 NOT NULL DEFO ‘3’
usr__id int4
output_channel__id int4 NOT NULL
tplate_type int2 NOT NULL DEFO 1
element_type__id int4
category__id int4
file_name text
current_version int4 NOT NULL
workflow__id int4 NOT NULL
desk__id int4 NOT NULL
published_version int4
deploy_status bool NOT NULL DEFO false
deploy_date timestamp
expire_date timestamp
active bool NOT NULL DEFO true
site__id int4 NOT NULL
Indexes
pk_template__id primary key ( id)
udx_template__file_name__oc unique ( file_name, output_channel__id)
fkx_category__template ( category__id)
fkx_element_type__template ( element_type__id)
fkx_output_channel__template ( output_channel__id)
fkx_site__template ( site__id)
fkx_template__desk__id ( desk__id)
fkx_template__workflow__id ( workflow__id)
fkx_usr__template ( usr__id)
Foreign Keys
fk_category__template ( category__id ) ref category ( id )
fk_desk__template ( desk__id ) ref desk ( id )
fk_element_type__template ( element_type__id ) ref element_type ( id )
fk_output_channel__template ( output_channel__id ) ref output_channel ( id )
fk_site__template ( site__id ) ref site ( id )
fk_usr__template ( usr__id ) ref usr ( id )
fk_workflow__template ( workflow__id ) ref workflow ( id )





Table template_instance
id serial NOT NULL
template__id int4 NOT NULL
version int4
usr__id int4 NOT NULL
file_name text
data text
note text
checked_out bool NOT NULL DEFO ‘false’
Indexes
pk_template_instance__id primary key ( id)
fkx_template__tmpl_instance ( template__id)
fkx_usr__template_instance ( usr__id)
idx_template_instance__note ( note)
Foreign Keys
fk_template__template_instance ( template__id ) ref template ( id )
fk_usr__template_instance ( usr__id ) ref usr ( id )





Table template_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_template_member__id primary key ( id)
fkx_member__template_member ( member__id)
fkx_template__template_member ( object_id)
Foreign Keys
fk_member__template_member ( member__id ) ref member ( id )
fk_template__template_member ( object_id ) ref template ( id )





Table user_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_user_member__id primary key ( id)
fkx_member__user_member ( member__id)
fkx_user__user_member ( object_id)
Foreign Keys
fk_member__user_member ( member__id ) ref member ( id )
fk_user__user_member ( object_id ) ref usr ( id )





Table usr
id int4 NOT NULL
login varchar( 128 ) NOT NULL
password bpchar NOT NULL
active bool NOT NULL DEFO ‘true’
Indexes
pk_usr__id primary key ( id)
Foreign Keys
fk_person__usr ( id ) ref person ( id )





Table usr_pref
id serial NOT NULL
pref__id int4 NOT NULL
usr__id int4 NOT NULL
value varchar( 256 ) NOT NULL
Indexes
pk_usr_pref__pref__id__value primary key ( id)
udx_usr_pref__pref__id__usr__id unique ( pref__id, usr__id)
idx_usr_pref__usr__id ( usr__id)
Foreign Keys
fk_pref__usr_pref ( pref__id ) ref pref ( id )
fk_usr__usr_pref ( usr__id ) ref usr ( id )





Table workflow
id serial NOT NULL
name varchar( 64 ) NOT NULL
description varchar( 256 ) NOT NULL
all_desk_grp_id int4 NOT NULL
req_desk_grp_id int4 NOT NULL
asset_grp_id int4 NOT NULL
head_desk_id int4 NOT NULL
type int2 NOT NULL DEFO 1
active bool NOT NULL DEFO true
site__id int4 NOT NULL
Indexes
pk_workflow__id primary key ( id)
fkx_grp__workflow__all_desk_grp_id ( all_desk_grp_id)
fkx_grp__workflow__asset_grp_id ( asset_grp_id)
fkx_grp__workflow__req_desk_grp_id ( req_desk_grp_id)
fkx_site__workflow__site__id ( site__id)
Foreign Keys
fk_grp__workflow__all_desk_grp_id ( all_desk_grp_id ) ref grp ( id )
fk_grp__workflow__req_desk_grp_id ( req_desk_grp_id ) ref grp ( id )
fk_grp__workflow__asset_grp_id ( asset_grp_id ) ref grp ( id )
fk_site__workflow__site__id ( site__id ) ref site ( id )





Table workflow_member
id serial NOT NULL
object_id int4 NOT NULL
member__id int4 NOT NULL
Indexes
pk_workflow_member__id primary key ( id)
fkx_member__workflow_member ( member__id)
fkx_workflow__workflow_member ( object_id)
Foreign Keys
fk_member__workflow_member ( member__id ) ref member ( id )
fk_workflow__workflow_member ( object_id ) ref workflow ( id )
Clone this wiki locally
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.