Skip to content

Instantly share code, notes, and snippets.

@fixlr
Created January 29, 2009 15:02
Show Gist options
  • Save fixlr/54569 to your computer and use it in GitHub Desktop.
Save fixlr/54569 to your computer and use it in GitHub Desktop.
DSpace: Determine Size of a bottom-level Sub-community
SELECT size_bytes
FROM bitstream , item2bundle, bundle2bitstream
WHERE item2bundle.bundle_id = bundle2bitstream.bundle_id
AND bundle2bitstream.bitstream_id = bitstream.bitstream_id
AND item2bundle.item_id = ANY(
SELECT item_id
FROM item
WHERE owning_collection = ANY(
SELECT collection_id
FROM community2collection
WHERE community_id = 53
)
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment