Why so many media tables?

(Dev Manual)


Why so many media tables?Screen shot 2011-03-01 at 2.37.41 PM.png

There seem to be a large number of medialink and media tables in the Relationship chart. This is to display a list view and detailed view of media for each category in the Context and Find areas of the database.


In order to show a list of all media associated with a single trench, I have to have a MediaLink and Media table related just to the Trench table. And then, in order to show the List and Detailed Views on Same Layout, I have to have two other tables but related slightly differently.


The first relationship from the trench is to an instance of the MediaLink table named MediaLinkDetailTrench. That is a simple Trench::TrenchName = MediaLinkDetailTrench::SerialSubject relationship. Then I need another simple relationship from the link back to the media table: MediaDetailTrench::FileName = MediaDetailTrench::ImageFileName. That will give me a portal to a list view of the media with the image file name (from the link table) and the caption (from the media table). But I need one other relationship to get the List and Detailed Views on Same Layout working: so I have the link table related to another instance of the media table, this one named MediaDetailTrench2, and related through MediaLinkDetailTrench::_GlobalFileNum = MediaDetailTrench2::FileName.


This basic relationship structure currently exists with the SU table as well. 


<- Shadow Tables Sync Scripts->