Note that there are some explanatory texts on larger screens.

plurals
  1. POAre modifiable join views a reasonable design choice?
    primarykey
    data
    text
    <p>To be clear, by <em>modifiable <strong>join</strong> view</em> I mean a view constructed from the joining of two or more tables that allows insert/update/delete actions that modify any/all of the component tables.</p> <p>This may be a postgres specific question, not sure. I am also interested if other DBMSs have idiosyncratic features for modifiable join views, since as far as I can tell, they are not possible in standard SQL.</p> <p>I'm working on a postgres schema, and some of my recent reading has suggested that it is possible to construct modifiable join views using instead rules (<code>CREATE RULE ... DO INSTEAD ...</code>). Modifiable join views seem desirable since it would allow for hiding strong normalization behind an interface, providing a mechanism for classic abstraction. Rules are the only option for implementation, since currently <a href="http://www.postgresql.org/docs/9.0/static/rules-triggers.html" rel="nofollow noreferrer">triggers cannot be set on views</a>.</p> <p>However, the first modifiable view I tried to design ran into problems, and I find out that many consider non-trivial rules to be harmful (see links in comments to <a href="https://stackoverflow.com/questions/5534927/how-to-write-a-delete-rule-on-a-view/5536199#5536199">this SO answer</a>). Also, I can't find any examples of modifiable join views on the web.</p> <p><strong>Questions (Edit to put finer points on the questions):</strong></p> <ul> <li>Do you have any experience with modifiable join views and can you provide a concrete example with select/insert/delete/update ability? </li> <li>Are they practical, i.e. can they be treated transparently without having to tiptoe around mines/black holes? </li> <li>Are they ever a good design choice, in terms of functionality/effort ratio and maintainability? </li> </ul> <p>Would greatly appreciate links to any examples/discussions on this topic. Thanks.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload