It's all about the answers!

Ask a question

Internal SCM VersionID field name needed.


Siegfried Oesterreicher (10713530) | asked Jul 22 '15, 2:32 a.m.
edited Jul 22 '15, 9:14 a.m. by Ralph Schoon (59.7k23643)
Hello,

I got the question  regarding the RTC internal Name of the SCM Version ID that looks like: 1@_ib6TAQVDEd-OHMj7Pjw0zw. The projects wants to populate this information into a field for further reference. Any hints ?

Thanks in advance
Siegfried.

Comments
Ralph Schoon commented Jul 22 '15, 3:01 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER

Field where? What do they intent to do with the information?


Siegfried Oesterreicher commented Jul 22 '15, 7:21 a.m.

Hello Ralph,

here is a picture I got from the person asked the question.

Is this field accessible and can it be copied to another field ?

Thanks in advance
Sigi

Accepted answer


permanent link
Ralph Schoon (59.7k23643) | answered Jul 22 '15, 8:08 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
A human can access them at the file properties:





You can search for getVersionIdentifiers() in the SDK and you will find e.g.

ScmVersionableIdentifierList versionIdentifiers = com.ibm.team.filesystem.cli.core.util.RepoUtil
                            .getVersionIdentifiers(
                                    scmService,
                                    Collections.singletonList(versionable.getStateId().getUuidValue()), config);


which looks like this:

    public static ScmVersionableIdentifierList getVersionIdentifiers(IScmRichClientRestService scmService, Collection<String> stateIds, IScmClientConfiguration config)
            throws FileSystemException {
        ParmsGetVersionableIdentifiers parms = new ParmsGetVersionableIdentifiers();
        parms.versionableStateIds = stateIds.toArray(new String[stateIds.size()]);
        ScmVersionableIdentifierList versionIdentifiers = null;
        try {
            versionIdentifiers = scmService.postGetVersionableIdentifiers(parms);
        } catch (TeamRepositoryException e) {
            throw StatusHelper.wrap(Messages.RepoUtil_CANNOT_DETERMINE_VERSION_IDS, e,
                    new IndentingPrintStream(config.getContext().stderr()));
        }

        return versionIdentifiers;
    }



Siegfried Oesterreicher selected this answer as the correct answer

One other answer



permanent link
Ralph Schoon (59.7k23643) | answered Jul 22 '15, 7:34 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
edited Jul 22 '15, 7:36 a.m.
Those numbers are the version Full Version ID's of the elements in SCM Controlled by this setting:



The ones above are shown if "Always show the full version ID" is checked. More human useable version numbers are presented when you uncheck the check box.

These version ID's are properties of the change set or file version and can potentially be accessed with the API. So you can access them and potentially get and store them somewhere.



Comments
Siegfried Oesterreicher commented Jul 22 '15, 7:38 a.m.

Hello Ralph,
do you have the RTC internal name of the field to check the accessibility?

Thanks
Sigi

Your answer


Register or to post your answer.