VersionControlServer.QueryHistory is not working when username is null with date range

RAMSANKAR MANTRY 96 Reputation points
2021-09-25T13:44:20.343+00:00

Hi

I am using the VersionControlServer.QueryHistory method to find the list of changesets committed by all users within a specific date range.
Below is my code snippet.

private void QueryChangesetByFromToDate(ref IEnumerable changesets)
        {
            changesets = this.versionControlServer.QueryHistory(
                       "$/",
                       VersionSpec.Latest,
                       0,
                       RecursionType.Full,
                       null,
                       FromDateVersion,
                       ToDateVersion,
                       Int32.MaxValue,
                       true,
                       false);
        }

This API is not working as expected. It is giving me all the changesets instead of those who are committed within the date range.

Note: This API is working fine incase I am giving user name.
The same API is also working when I am giving range of two chageset IDs.

Can someone help here ?
Thanks.

C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,292 questions
{count} votes