GitStats
Retrieve statistics about all branches within a repository, sliced across all repositories.
Table Specific Information
Select
The add-in uses the Azure DevOps API to process WHERE clause conditions built with the following columns and operators:
- ProjectId supports the '=' operator.
- RepositoryId supports the '=' operator.
- Name supports the '=' operator.
- VersionOptions supports the '=' operator.
- Version supports the '=' operator.
- VersionType supports the '=' operator.
NOTE: RepositoryId is required in order to query GitStats.
For example:
SELECT * FROM GitStats WHERE RepositoryId = '02b4a62d-2f5f-4d69-8420-29257dcc8051' SELECT * FROM GitStats WHERE RepositoryId = '02b4a62d-2f5f-4d69-8420-29257dcc8051' AND VersionOptions = 'none' SELECT * FROM GitStats WHERE RepositoryId = '02b4a62d-2f5f-4d69-8420-29257dcc8051' AND Name = 'master'
Columns
Name | Type | References | Description |
Name [KEY] | String | Name of the branch. | |
ProjectId | String | Id of the project. | |
RepositoryId | String |
Repositories.Id | Id of the repository. |
AheadCount | Integer | Number of commits ahead. | |
BehindCount | Integer | Number of commits behind. | |
CommitId | String | ID (SHA-1) of the commit. | |
IsBaseVersion | Boolean | Indicates whether this is base version. |
Pseudo-Columns
Pseudo column fields are used in the WHERE clause of SELECT statements, and offer a more granular control over the tuples that are returned from the data source. Unless otherwise specified, only the = operator is permitted when filtering on pseudocolumns.
Name | Type | Description | |
VersionOptions | String | Version options - Specify additional modifiers to version (e.g Previous).
The allowed values are firstParent, none, previousChange. | |
Version | String | Version string identifier (name of tag/branch, SHA1 of commit). | |
VersionType | String | Version type (branch, tag, or commit). Determines how Id is interpreted.
The allowed values are branch, commit, tag. |