ostreifel / wiql-editor Goto Github PK
View Code? Open in Web Editor NEWSearch work items with wiql queries.
Home Page: https://marketplace.visualstudio.com/items?itemName=ottostreifel.wiql-editor
License: MIT License
Search work items with wiql queries.
Home Page: https://marketplace.visualstudio.com/items?itemName=ottostreifel.wiql-editor
License: MIT License
So this will almost certainly make me look stupid, but, that's fine.
I'm in Azure Devops, but when I go to the boards and then create a query, I don't see the WIQL Editor tab anywhere. I'm sure I'm missing something obvious, but my question is, what am I missing? The ADO native editor sucks, and I really need the ability to write WIQL queries.
Thanks!
Hi
I am facing issue of two different responses using different tools
with Wiql playgorund i am able to get the result as table but when
Query : SELECT
[System.Id],
[System.WorkItemType],
[System.Title] FROM workitems
WHERE [System.AreaPath] = 'Test Agile Project\Winter Sprint 1'
and [System.state]='New'
Wiql playgorund Results:
793 User Story Winter Sprint 1 user story 7
792 User Story Winter Sprint 1 user story 6
Found 2 results
with postman using POST url the response is like as below for the same query
postman Results
{
"queryType": "flat",
"queryResultType": "workItem",
"asOf": "2017-10-26T18:40:00.95Z",
"columns": [
{
"referenceName": "System.Id",
"name": "ID",
"url": "https://tfs.XYZ.edu/tfs/ITS%20AppDev/_apis/wit/fields"
},
{
"referenceName": "System.WorkItemType",
"name": "Work Item Type",
"url": "https://tfs.XYZ.edu/tfs/ITS%20AppDev/_apis/wit/fields"
},
{
"referenceName": "System.Title",
"name": "Title",
"url": "https://tfs.XYZ.edu/tfs/ITS%20AppDev/_apis/wit/fields"
}
],
"workItems": [
{
"id": 792,
"url": "https://tfs.XYZ.edu/tfs/ITS%20AppDev/_apis/wit/workItems/792"
},
{
"id": 793,
"url": "https://tfs.XYZ.edu/tfs/ITS%20AppDev/_apis/wit/workItems/793"
}
]
}
So I am expecting the column values to display in postman response. Is there any way i can get display the column values instead of just the URLs of workitems
Thanks
Pavan
Hi there
I'd like to find out if this repo is being actively maintained?
Would love to use it but I cannot get permission from my company to do so due to the lack of recent commits.
Please Advise?
@ostreifel @mmanela @cschleiden
When I run 'SELECT title FROM workitems WHERE EVER Tags CONTAINS 'asdf'', only the work items that currently have the tag are returned.
Tried to migrate a query from one instance to another via WIQL and it fails:
Workaround: save the empty query first, then edit it on the new instance
Describe the bug
I've been using the EVER operator against [system.iteration.path] to allow us to track work items that have spilled over to another sprint.
I'm able to get the results in WIQL which has been great even though there is a red warning icon displayed at the start of the line.
When I select "Open in queries", the results are displayed in VSTS but I'm unable to save the query. I get a message "The operator for row 3 is not recognized".
In editor view I can see that the WAS EVER operator has a red exclamation mark. I'd really appreciate any advice you have as we use dynamic queries quite often.
Here's a snippet of my query with the project/team replaced with generic terms:
SELECT
[System.Id],
[System.WorkItemType],
[System.Title],
[System.State],
[Microsoft.VSTS.Scheduling.StoryPoints],
[System.AreaPath],
[System.IterationPath]
FROM workitems
WHERE
[System.TeamProject] = @project
AND [System.WorkItemType] = 'User story'
AND [System.AreaPath] IN ('project\team')
AND [System.IterationPath] EVER @CurrentIteration('[project]\team') -1
AND [System.IterationPath] = @currentiteration('[project]\team')
ORDER BY [System.Id] ASC
ASOF '12/03/19 17:00'
Environment:
Screenshots
To Reproduce
Steps to reproduce the behavior:
See above
Expected behavior
Custom query can be saved in VSTS
Additional context
N/A
Describe the bug
To Reproduce
Expected behavior
using REST API this query works
/POST https:////***/_apis/wit/wiql?timePrecision=true&api-version=5.0
{
"query": "SELECT [System.ID],
[System.Title], [System.State],[System.CreatedDate] FROM WorkItems WHERE [System.TeamProject]='MyProject' AND [System.CreatedDate] = '2019-06-20T08:51:14.863Z'"
}
in WIQL the same query fail because timePrecision is not enable by default
At the moment you can compare 2 Date but not 2 DateTime
Hi, I spent a couple of hours trying to get your project to compile, but it can't find monaco. Are you able to compile this from a clean download?
Describe the bug
When the new preview is turned on (turn on preview "New Boards Hubs"), there is an issue saving the query. Somehow the callback argument is lost
Environment:
To Reproduce
Steps to reproduce the behavior:
Expected behavior
The query should save properly
Additional context
n/a
Calling Wiql endpoint via Azure devops REST API "WIQL query by ID" provides only work items' ids and links to the workitem, but not columns defined in the query itself.
Doing the same in web interface provides columns specified in the query.
Describe the bug
'_apis/tagging/scopes/' not support now
Environment:
Azure 2019
Screenshots
To Reproduce
add tags SQL
Using version 2.0.76 in TFS 2018 Update 3 the playground functionality no longer works in Edge.
It will hang on load. It works uysing Chrome.
In the JavaScript console we get:
at ./scripts/getCurrentTheme.ts (http://tfs.company.com:8080/tfs/_apis/public/gallery/publisher/ottostreifel/extension/wiql-editor/2.0.76/assetbyname/dist/playground.js:357:1)
at __webpack_require__ (http://tfs.company.com:8080/tfs/_apis/public/gallery/publisher/ottostreifel/extension/wiql-editor/2.0.76/assetbyname/dist/playground.js:20:12)
at eval code (eval code:10:22)
at ./scripts/wiqlEditor/wiqlEditor.tsx (http://tfs.company.com:8080/tfs/_apis/public/gallery/publisher/ottostreifel/extension/wiql-editor/2.0.76/assetbyname/dist/playground.js:729:1)
at __webpack_require__ (http://tfs.company.com:8080/tfs/_apis/public/gallery/publisher/ottostreifel/extension/wiql-editor/2.0.76/assetbyname/dist/playground.js:20:12)
at eval code (eval code:6:22)
at ./scripts/wiqlPlayground/playground.ts (http://tfs.company.com:8080/tfs/_apis/public/gallery/publisher/ottostreifel/extension/wiql-editor/2.0.76/assetbyname/dist/playground.js:741:1)
at __webpack_require__ (http://tfs.company.com:8080/tfs/_apis/public/gallery/publisher/ottostreifel/extension/wiql-editor/2.0.76/assetbyname/dist/playground.js:20:12)
at Anonymous function (http://tfs.company.com:8080/tfs/_apis/public/gallery/publisher/ottostreifel/extension/wiql-editor/2.0.76/assetbyname/dist/playground.js:84:11)
at Anonymous function (http://tfs.company.com:8080/tfs/_apis/public/gallery/publisher/ottostreifel/extension/wiql-editor/2.0.76/assetbyname/dist/playground.js:1:584)```
Whenever I open up the query editor and paste in a new query, then save, the query is not saved. I've tried this repeatedly, with different queries and after refreshing the browser. I'm using Safari on a Mac. This worked fine a few weeks ago.
Describe the bug
Query Across Projects Stopped Working
Environment:
To Reproduce
Data should be returned from other projects. This stopped working last week but then it started working again even though I made no changes to the query.
Expected behavior
I expect results from multiple projects.
Additional context
Add any other context about the problem here.
Hi Otto,
could you please add the license under which the WIQL-Editor is published?
Thank you
Carina
We've been using Enhanced Query Export for months without any issues. It's no longer including all of the fields from the Queries.
Prueba1
I try to use group by equal in SQL Language, like that:
SELECT
COUNT(1) AS TOTAL,
[System.Tags]
FROM workitems
WHERE [System.TeamProject] = @project
GROUP BY [System.Tags]
ORDER BY [System.ChangedDate] DESC
I can search by Tag, provided I specific the exact Tag. And that's how queries work even without WIQL.
I was hoping it would be possible to perform Tag wildcard search using WIQL. E.g. all Tags containing %wave%. Tried various combinations without success. Any suggestions?
Hi,
I couldn't get the export option working on TFS, It prompts for filename but does nothing.
Regards
Anirudh
(My team and I are really thankful for your work, please take this issue as a bug report for functionality we deeply enjoy using).
Steps to reproduce:
1.) From the Work Queries section in TFS, select a query on the left
2.) Click the Edit Wiql button in the results section
3,) That brings you to the Wiql Editor...
4.) Use your mouse's back button to navigate backwards
Expected result:
You go back to the query list and results page (perhaps with a warning asking if you want to save your changes)
Actual result:
The screen doesn't change.
This issue is occurring on TFS 2015 Update 4 (on premises).
In the playground, I run a query, and I get a list of responses. When I click any of the links, I get the following error:
Ajax request failed with status: Unauthorized.
TFS.Core.Ajax.AjaxException: Ajax request failed with status: Unauthorized.
Refreshing and hard-refreshing do nothing. However, if I middle click the link, it works as expected.
The same thing happened just now when clicking the "Report an issue" link at the top of the page; I got a bunch of Refused to load the stylesheet '...' because it violates the following Content Security Policy directive: "style-src 'unsafe-inline' assets-cdn.github.com".
errors. Middle clicking fixes this issue as well.
Putting the github issue aside (as I haven't investigated that at all):
I looked into the cookies on the pages that are giving the errors: EditThisCookie shows all the cookies one would expect, however, looking into the Network tab in Chrome Dev Tools shows that all the Ajax requests are being sent without any cookies.
Looking into the iframe the results are being served from, window.document.location
is empty. I have a feeling this is the root of the issue; chrome is making ajax requests based on the cookies applicable to window.document.domain, and finding none,
I ran the $("a.row").attr("target", "_parent");
in the console and re-tried clicking any of the work item links and they all worked as expected, however they no longer opened in new tabs.
Please let me know if I can provide any more information that would assist you. I may have time to look into the error myself in about three weeks if you don't have time before then. Thanks.
TFS Version: TFS 2015 Update 3
Extension Version: 1.6.22
Running the following query:
SELECT [System.Id], [System.State], [System.WorkItemType]
FROM WorkItemLinks
WHERE
[Source].[System.Id] = 107932
AND [System.Links.LinkType] = 'System.LinkTypes.Hierarchy-Forward'
AND [Target].[System.WorkItemType] <> ''
ORDER BY [System.Id]
The only thing displayed in the results is: "Found {#} results" (but with an actual number). Screenshot attached.
I've also done my best to try and debug this a bit, though I don't know how helpful it will be, but here goes (keeping in mind I know almost nothing about React.js):
As best I can tell, React is having a problem rendering the rows that are created in WorkItemRow.render()
, since the results table is empty:
<div id="query-results">
<div data-reactid=".1">
<table data-reactid=".1.0">
<tbody data-reactid=".1.0.0"></tbody>
</table>
<div data-reactid=".1.1">Found 11 results</div>
</div>
</div>
I set breakpoints in the render function to try and capture the results of return (React.createElement("a"...
. I put the first 5 or 6 row objects into an array, and used CircularJSON to stringify them. The resultant JSON is also attached. Maybe you can find something there that's out of the ordinary compared to a non-WorkItemLinks result.
How do I grant permissions to Contributors to use Wiql Playground? (TFS 17 OnPrem)
They can see it, but it won't let them use it.
I'm trying to use the extension of DevOps 2020 On-Prem Environment but every time I try to run the extension I receive the error below:
An undefined error occurred while attempting to connect to the server. Status code 0: .
Server Version is Version Dev18.M170.6
Client is Edge - Version 87.0.664.66 (Official build) (64-bit)
When I try to save my wiql given below, I get error: wiql error saving query Expected end of string. The error is caused by
If I remove the code snippet “(‘[MyProject]\MyTeam’)” I can save. What is wrong in the syntax for the @currentIteration ?
SELECT
[System.Id],
[System.WorkItemType],
[System.Title],
[System.AssignedTo],
[System.State],
[System.Tags]
FROM workitems
WHERE
[System.TeamProject] = ‘MyProject’
AND (
[System.WorkItemType] = ‘User Story’
OR [System.WorkItemType] = ‘Defect’
)
AND [System.State] <> ‘’
AND [Invensys.Team] = ‘MyTeam’
AND [System.IterationPath] UNDER @currentIteration(‘[MyProject]\MyTeam’)
ORDER BY [System.Id]
Execute this query in Wiql Playground
SELECT
[System.Id],
[System.WorkItemType],
[System.Title],
[System.State],
[System.AreaPath],
[System.AreaLevel1],
[System.AreaLevel2],
[System.RelatedLinkCount],
[System.IterationPath]
FROM workitems
WHERE
[System.TeamProject] = @project
AND [System.WorkItemType] = 'Epic'
AND [System.RelatedLinkCount] > 1
ORDER BY [System.ChangedDate] DESC
And you get all the columns. Add [System.History] to the projection and the ID, AreaLevel1, AreaLevel2, and RelatedLinkCount fields magically disappear!
This may be more of a question about TFS Extensions than about this particular extension. Is it possible to restrict viewing of this extension to a particular group of TFS users?
Thanks!
But!
working synonyms for select id from workitems
is:
select id from workitem
select id from issues
select id from issue
working synonym for select id from workitemlinks
is select id from links
It would be nice to see query time if possible?
thanks, Jan
Describe the bug
Have created a query using WIQL Playground but the results appear to be limited to the first 50 rows.
Message at foot of report "Showing first 50 results" without any obvious sign/link to show additional results.
When we click "Open in queries" CTA then the vsts UI displays 100 results.
We need to use WIQL because the asof functionality isn't available in vsts.
Environment:
Screenshots
No errors in the dev console - returns 200 response
Expected behavior
I expect to see all work items that match the query to be displayed when I press "Run"
Additional context
N/A
Issue:
microsoft.zip
My Query:
SELECT
[System.Id],
[System.WorkItemType],
[System.Title],
[System.AssignedTo],
[System.State],
[System.Tags]
FROM workitems
WHERE
[System.TeamProject] = @project
AND NOT [System.Tags] CONTAINS 'MyTag'
ASOF '2020/7/23'
Result in list of work items including work items with Tags 'MyTag'
See attached screenshots
I am able to reproduce this on 18.170.30525.1 (Azure DevOps Server 2020)
For adding the ASOF part of the query the following extension is used : https://marketplace.visualstudio.com/items?itemName=ottostreifel.wiql-editor
Hopefully you can help in resolving this issue.
Thanks in advance.
Answer microsoft:
I have checked and concluding you that the ASOF parameter doesn’t work as expected in Azure DevOps 2019 and 2020 respectively.
Also, upon checking with internal team, they mentioned that we don’t own the Wiql Editor extension- https://marketplace.visualstudio.com/items?itemName=ottostreifel.wiql-editor#qna
We would like you to reach out to respective extension provider by creating an issue on Issues · ostreifel/wiql-editor · GitHub
You would get the right team engagement who can help you addressing this.
As we are from Azure DevOps team, we couldn’t provide much help here. I am sorry about that
Should you have any questions feel free to write to me.
Using AsOf with the @today variable minus a number, e.g. "asof @today-7" returns:
Expecting end of string. The error is caused by <<-7>>.
From the wiql editor, if I add asof ‘2022-11-22T23:00:00’ to the query, I can run it, but I cannot save it.
Hitting the save button does not do anything. The user does not see an error message. When I looked at the network traffic, there was an error thrown when the button was being clicked. See attachment.
When selecting fields to return in the query, the [Closed Date] field is made available. No errors are shown in the script. However, including this fields results in zero rows being returned.
Hello,
When I created a query and return respective results, "date colums" aka "Closed Date", "Created Date", respectiva value is formatted to UTC, not local time.
Only recently (within 2 weeks) the Intellisense is not working in the Wiql Playground.
There are a few columns I don't remember the full name so I cannot add it in the query. I have tried in edge, chrome and an inprivate window.
It seems when editing a query clicking the Save button doesn't do anything i.e. not saved, no error. Exporting works with the modified query however.
There should be possibility to filter by "changed date and time" in Wiql. Even better if you can this feature in default query section. Basically i want to query work items which changed during last 'x' hours.
in wiql -
System.ChangedDate ='12/07/2018, 6:42:45' or System.ChangedDate =('12/07/2018, 6:42:45')-1hour
I would like to have the ability to build ad-hoc single use queries, that don't need to be saved. Simply generate the query string based on the DevOps WIQL query string syntax:
https://{ServerName}/{CollectionName}/{ProjectName}/_workitems?_a=query&wiql={Encoded WorkItemQueryLanguage}
If this could be done without having the save the query first, that would be great. Otherwise exporting to query string would still be helpful to use the query as a scratchpad to generate the query string.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.