Skip to content

FEAT: Applying Restrictions to a Diagram #865

@dimitri-yatsenko

Description

@dimitri-yatsenko

Feature Request

Problem

DataJoint needs an effective way of specifying a subset of the data from the database for export, deletion, publishing, backups, synchronization, and sharing.

dj.Diagram objects already provide powerful ways of specifying a specific subset of tables through their set operators: union, difference, intersection, etc. Adding the ability to restrict the data in the tables of a diagram would complete the functionality necessary for specifying a cross-section of the data in the database.

Requirements

  1. dj.Diagram must provide a way to apply a restriction to any of its tables.
  2. Restrictions must propagate down through dependencies and up from part to master when necessary.
  3. If a restriction causes a table to become empty, the table is excluded from the diagram.

Justification

Specifying a subset of the data in the database across multiple tables and schemas is a basic functionality that would allow many other operations. Deletions and backups are prime examples.

Alternative Considerations

The cascading delete feature already allows deleting a cross-section of the data based on a restricted table.

Related Issues

#864 - backup and restore
#560 - export
#151 - cascading deletes

Metadata

Metadata

Labels

featureIndicates new features

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions