DSpace SQL Snippets

Here are some SQL queries you can copy and paste into DSpace.

    1. Select/update the access policy to Anonymous for all thumbnails that have their group set as 2 (e.g. anu-archives) :

      Or do an individual one by adding:

      where that ID is found on the authorisations page in the Full Item Record view.

      Change the above to BRANDED_PREVIEW to affect the permissions on those as well.

      Remove this SQL from the above to affect ALL thumbnails/previews, not just those in group


    2. Find all items that have their original bitstream open to the public: 

      NB. This needs tweaking:

    3. Using subselects to filter results for various conditions: 

      This SQL selects the relation.ispartof field (42) for all handles in the sub query (i.e. the ones that have NARU in the affiliation field (121)).

    4. Find massive files: 

      Get the handle of these big files:

    5. Find all handles that correspond to a specific Metadata Field within a given collection: 

One Comment

Add a Comment

Your email address will not be published. Required fields are marked *