ODBC guide

Query work items modified after a date (dynamic)


Use placeholder functions (e.g. monthstart, today, yearend) and arithmetic (e.g. monthstart-1d) to build dynamic dates in your WIQL query so the same statement always reflects the intended period without manual date changes. The placeholder is evaluated before the query is sent to Azure DevOps.

For placeholder syntax and options see placeholder functions. For WIQL see WIQL syntax.

SELECT * FROM WorkItems WITH (Query='SELECT * FROM WorkItems 
WHERE [System.TeamProject]=''ProductTesting''
	AND [System.ChangedDate] >= ''<<monthstart-1d,FUN_TO_DATE>>'' 
ORDER BY [System.ChangedDate] DESC
	')