Planning Center Publishing Data Model - Complete Documentation
This document provides complete documentation of ALL tables in the Planning Center Publishing data model in Parable, including all entity tables and relationship tables with full field definitions.Overview
The Publishing module manages your church’s media content distribution, containing:- 14 entity tables - Episodes, series, channels, speakers, and supporting data
- 1 relationship table - Speakerships linking episodes to speakers
- Comprehensive metrics - View counts, downloads, and engagement tracking
Visual Data Model
Core Entity Relationships
Key Relationships Explained
Content Hierarchy:CHANNELis the top-level podcast/media feedSERIESorganizes episodes by topic or themeEPISODEis the individual sermon, message, or content piece- Hierarchy: Channel → Series → Episode
CHANNEL_DEFAULT_TIMEdefines recurring publish scheduleCHANNEL_NEXT_TIMEoverrides next publish date/timeEPISODE_TIMEtracks when specific episodes were/will be published- Supports both recurring schedules and one-off publications
EPISODE_RESOURCEstores multiple formats per episode- Kinds include: audio, video, PDF notes, etc.
- Each resource has URL and file size tracking
- Single episode can have audio, video, and supplementary files
SPEAKERdefines individuals who present contentSPEAKERSHIPlinks episodes to speakers (many-to-many)- Single episode can have multiple speakers
- Speakers can appear in multiple episodes/series
EPISODE_STATISTICtracks engagement metrics- Metrics: total plays, total downloads, time periods
- Historical tracking with date ranges
- Enables trend analysis and content performance review
NOTE_TEMPLATEprovides reusable sermon note formatsONBOARDINGtracks publishing setup completionORGANIZATIONlinks to Planning Center organization settings
- Times and resources use
parent_idpattern - Episode times belong to episodes
- Episode resources belong to episodes
- Channel times belong to channels
Query Requirements
Schema Prefix
IMPORTANT: All tables in the Planning Center Publishing module are in theplanning_center schema. You MUST prefix all table names with planning_center. in your queries.
✅ CORRECT: SELECT * FROM planning_center.publishing_episodes
❌ INCORRECT: SELECT * FROM publishing_episodes
Row Level Security (RLS)
This database uses Row Level Security (RLS) to automatically filter data based on:- tenant_organization_id: You only see data for your current organization
- system_status: You only see ‘active’ records by default
- ❌
WHERE tenant_organization_id = 1(unnecessary) - ❌
WHERE system_status = 'active'(unnecessary)
Complete Table Inventory
Core Content Tables
1. publishing_episodes
Individual sermons, messages, and content pieces.
2. publishing_series
Sermon series and content collections.
3. publishing_channels
Distribution channels and platforms.
4. publishing_speakers
Speaker profiles and information.
Relationship Tables
5. publishing_speakerships
Links episodes to speakers (junction table).
Resource and Media Tables
6. publishing_episode_resources
Files and resources attached to episodes.
7. publishing_note_templates
Templates for sermon notes and outlines.
Scheduling Tables
8. publishing_episode_times
Publishing schedule for episodes on different channels.
9. publishing_channel_default_times
Default publishing schedules per channel.
10. publishing_channel_next_times
Upcoming scheduled publishes per channel.
Analytics Tables
11. publishing_episode_statistics
View counts, downloads, and engagement metrics.
12. publishing_episode_statistic_times
Statistics tracked over time periods.
Configuration Tables
13. publishing_organizations
Organization-level publishing settings.
14. publishing_channel_channel_default_episode_resources
Default resources automatically attached to episodes per channel.
Administrative Tables
15. publishing_onboardings
Tracks onboarding process for new channels.
System Fields
All tables include these system fields for data management:tenant_organization_id- Multi-tenant organization identifiersystem_status- Data lifecycle status (active,transferring,stale)system_created_at- When the record was created in Parablesystem_updated_at- When the record was last updated in Parable
Row Level Security
All tables implement Row Level Security (RLS) to ensure tenant isolation:Data Integrity Rules
- Schema Qualification: Always use
planning_center.prefix for all table references - Row Level Security: RLS automatically handles multi-tenancy and status filtering - do not add manual filters
- Monetary Values: Any monetization or purchase amount columns are stored in cents - divide by 100.0 for display
- Media Flags: Use booleans like
needs_video_urlandneeds_library_audio_or_video_urlto identify missing assets instead of relying onsystem_status - Direct ID Columns: Tables such as
publishing_episodes,publishing_series, andpublishing_speakershipsexpose direct IDs for performance-sensitive joins
Common Mistakes to Avoid
-
Missing Schema Prefix
- ❌
FROM publishing_episodes - ✅
FROM planning_center.publishing_episodes
- ❌
-
Adding Redundant RLS Filters
- ❌
WHERE tenant_organization_id = 1 AND system_status = 'active' - ✅ Trust RLS to handle this automatically
- ❌
-
Joining Without Schema
- ❌
JOIN publishing_series s ON ... - ✅
JOIN planning_center.publishing_series s ON ...
- ❌
-
Skipping Currency Conversion
- ❌
SELECT purchase_price_cents as purchase_price - ✅
SELECT purchase_price_cents / 100.0 as purchase_price
- ❌
Performance Considerations
-
Indexes: All tables have optimized indexes on:
- Primary keys and entity IDs
- Join columns and foreign keys
- Date columns for time-based queries
-
Query Optimization:
- Always use the
planning_center.schema prefix - RLS handles tenant and status filtering automatically
- Filter by publication state or media availability when relevant
- Consider CTEs for aggregating view/download metrics
- Use direct ID columns when available instead of relationship tables
- Always use the
Data Synchronization
Publishing data is synchronized through Temporal workflows:- Master Workflow - Orchestrates all child workflows
- Independent Entities - Channels, Series, Speakers, Organizations
- Dependent Entities - Episodes (depends on channels)
- Related Data - Resources, times, statistics (depends on episodes)
- Junction Tables - Speakerships linking episodes to speakers
Usage Tips
- Trust RLS for active data - Skip manual
system_statusor tenant filters - Join through IDs - Use
episode_id,series_id,speaker_id - Consider NULL values - Many fields are optional
- Use JSONB operators for nested data in
art,settingsfields - Aggregate statistics over time periods for trends
Common Join Patterns
Episodes with Series and Speakers
Episodes with Statistics and Resources
Data Quality Notes
- Episode
published_live_atindicates published content - Series may have NULL
ended_atfor ongoing series - Statistics are point-in-time snapshots, use latest for current counts
- Speakerships table enables many-to-many episode-speaker relationships
- Channel IDs in episodes indicate primary publishing channel
This data model enables comprehensive media analytics and content management for your church’s publishing ministry.