x29a
x29a

Reputation: 1781

Cleartool difference between -element and -version

When searching for a way to find all files in a clearcase repo that changed since date X i found two approaches

cleartool find . -type f -branch "brtype(abranch)" -element "{created_since(10-Jan)}" -print

as stated here

and

cleartool find . -type f -branch "brtype(abranch)" -version "created_since(10-Jan)" -print

as (though modified to resemble the same branch) found here

What is the difference between the created_since filter in -version and -element? The results do differ.

Upvotes: 1

Views: 577

Answers (1)

VonC
VonC

Reputation: 1323593

In "ClearTool: Finding changes from specific date", I had to use -version in order to check for updated directories and detect deleted files.

But in "how to find files in a given branch", since the search is limited to files, I only had to check for files "created" (added to source control, hence the -element) since a certain date. I didn't have to check to modification in that question.

The cleartool find allows to filter on:

  • -element: Selects element objects using a VOB query; all of the selected element's branches and versions are also selected.
    Using this option with a brtype query makes find -all much faster in a large VOB where the specified branch type exists on a relatively small number of elements.

Note: I used the find + -ele brtype approach in "find files in clearcase" or "UCM-Clearcase - How to find new undelivered files for a given “stream”".

  • -version: From the set of objects that survived the element-level and branch-level queries (if any), selects version objects using a VOB query.

Upvotes: 1

Related Questions