Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply

The query specified in the URI is not valid: VS403522: The property 'Description' is not available

Hi,

 

I am trying to query ADO data using OData. My challenge is unable to query the "Description" field. The Below Error Appears

 

The query specified in the URI is not valid: VS403522: The property 'Description' is not available

 

The description is part our of work Items, yet unable to get that field in $metadata or normal work item query.

3 REPLIES 3
ferryv
Resolver I
Resolver I

The Description (or any other longtext field) is not available via the standard oData feed. You can retrieve it via VSTS.Contents. I previously wrote a linkedin post on this after I worked it out myself. 

 

You essentially make 2 calls. One to retrieve the workitem IDs (either via oData.Feed or Web.Contents) and another using that workitem ID to retieve the Description, etc.

 

So for instance using power query, you could use something similar to this (change OrgA and ProjA to your organisation and Project as well as other fields and other filter criteria):

 

let
 
#"Retrieve oData" = Table.FromRecords({[
 
FeedData= OData.Feed("https://analytics.dev.azure.com/OrgA/_odata/v3.0-preview/WorkItems?" 
&"$filter=(Area/AreaPath eq 'ProjA\Sandbox' and Project/ProjectName eq 'ProjA' and WorkItemType eq 'Product Backlog Item')"
&"&$select=WorkItemId,Title,State,WorkItemType,Priority")
 
]}),
 
#"Expand Data" = Table.ExpandTableColumn(#"Retrieve oData", "FeedData", {"WorkItemId",  "Title", "State","WorkItemType", "Priority"}, {"WorkItemId", "Title", "State","WorkItemType", "Priority"}),
 
#"Retrieve VSTS Data" = Table.AddColumn(#"Expand Data","VSTS", each Json.Document(VSTS.Contents("https://dev.azure.com/OrgA/ProjA/_apis/wit/workitems/" &Number.ToText([WorkItemId])))),
    
#"Expanded VSTS" = Table.ExpandRecordColumn(#"Retrieve VSTS Data", "VSTS", {"fields"}, {"VSTS.fields"}),
 
#"Expanded VSTS.fields" = Table.ExpandRecordColumn(#"Expanded VSTS", "VSTS.fields", {"System.Description", "Microsoft.VSTS.Common.AcceptanceCriteria"}, {"VSTS.fields.System.Description", "VSTS.fields.Microsoft.VSTS.Common.AcceptanceCriteria"})
 
in #"Expanded VSTS.fields"

You should get something similar to this:

 

ferryv_0-1672940950909.png

 

See also: https://www.linkedin.com/pulse/retrieve-long-text-fields-from-azure-devops-powerbi-van-der-vorst/

 

It also explains how to strip out the HTML, etc.

@ v-yalanwu-msft

Thank you for your response. 

 

So how do I get the Description field in my Odata query? This error comes only when i add the description field..

 

Here is my sample query

= OData.Feed("https://analytics.dev.azure.com/OrgName/ProjectName/_odata/v3.0-preview/WorkItems?" & "$filter=WorkItemType eq 'Risk'" & "&$select= WorkItemId, InProgressDate, CompletedDate, LeadTimeDays, CycleTimeDays, ProjectSK, WorkItemRevisionSK, AreaSK, Revision, Watermark, Title,Severity, Probability,WorkItemType, ChangedDate, CreatedDate, State, BusinessValue, ClosedDate, Priority, ResolvedDate, DueDate, Effort, OriginalEstimate,CompletedWork, RemainingWork, StartDate, StoryPoints, TargetDate, ParentWorkItemId, TagNames, StateCategory" & "&$expand=Description($select=WorkItemId)", null, [Implementation="2.0"])

 

 

v-yalanwu-msft
Community Support
Community Support

Hi, @Sabarikumar7579 ;

Queries that violate an OData error rule will result in a failed response with a 400 (Bad Request) status code. Associate messages don't appear within the property. Instead, they'll generate an error message in the property in the JSON response.

vyalanwumsft_0-1668653469237.png

OData Analytics query guidelines - Azure DevOps | Microsoft Learn
Best Regards,
Community Support Team _ Yalan Wu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors