Export (0) Print
Expand All

List Work Item Fields and View Attributes Assigned to Fields

You can generate a list of all work item fields that are defined in a team project collection by using the witadmin listfields command-line tool. You can use this list to understand the types of fields that are already defined and to select one of them for use in a new work item type or add to an existing work item type. Also, you can list the attribute assignments defined for a specific field and determine which fields are used by which team projects.

In this topic

Required Permissions

For the team project collection where the work item type fields are defined, you must be a member of the Readers group or have your View work items in this node permission set to Allow.

To list all fields in a team project collection

  1. Open a Command Prompt window.

  2. Change to the directory that contains the work item types that you want to list, by typing the following command and then pressing Enter.

    cd ..Drive:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\

  3. List a work item field by typing the following command at the command prompt, and then pressing Enter.

    witadmin listfields /collection:http://ServerName:Port/VirtualDirectoryName/CollectionName /n:FieldName
    

    Field and attribute information appears for the named field, as follows in this example.

    Field: Microsoft.VSTS.Common.Issue
    Name: Issue
    Type: String
    Reportable As: dimension
    Use: Adventure Works (Shared Steps), AW Future (Shared Steps), AW Current (Shared Steps)
    Indexed: False
    

    The Use parameter indicates the name of each project and the work item type where the field is used. For more information about field attributes, see Using System Fields and Fields Defined by the MSF Process Templates.

To list all fields in a team project collection

  1. Open a Command Prompt window.

  2. Change to the directory that contains the work item types that you want to list, by typing the following command and then pressing Enter.

    cd ..Drive:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE\

  3. List the fields by typing the following command at the command prompt, and then pressing Enter.

    witadmin listfields /collection:http://ServerName:Port/VirtualDirectoryName/CollectionName 
    

    Field information for all the fields for the named project collection appears.

To list fields that are not being used by any work item type

  1. Open a Command Prompt window.

  2. Change to the directory that contains the work item types that you want to list, by typing the following command and then pressing Enter.

    cd ..Drive:\Program Files\Microsoft Visual Studio 10.0\Common7\IDE

  3. List the fields that are no longer being used by any work item types by typing the following command at the command prompt, and then pressing Enter.

    witadmin listfields /collection:http://ServerName:Port/VirtualDirectoryName/CollectionName /unused
    

    Field and attribute information appears for each field that is not being used, as follows in this example.

    Field: Microsoft.VSTS.CMMI.TaskType
    Name: Task Type
    Type: String
    Reportable As: dimension
    Use: Not In Use
    Indexed: False
    
    Field: Microsoft.VSTSUE.Common.Flag
    Name: Flag
    Type: String
    Reportable As: dimension
    Use: Not In Use
    Indexed: False
    
    Field: Microsoft.VSTSUE.Common.Progress
    Name: Progress
    Type: String
    Reportable As: dimension
    Use: Not In Use
    Indexed: False
    

Community Additions

ADD
Show:
© 2015 Microsoft