-
Notifications
You must be signed in to change notification settings - Fork 191
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement sorting of query history by name, date, and result count #777
Conversation
@@ -400,6 +400,7 @@ export class InterfaceManager extends DisposableObject { | |||
} | |||
); | |||
const resultSet = transformBqrsResultSet(schema, chunk); | |||
results.setResultCount(resultSet.schema.rows); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a little confusing. The alerts
table has 33 results in this example, but the #select
table has 3906 results. I think people would expect that the result count matches the number of rows in the default table (in this case, it's alerts
).
I'm not entirely sure why there is a difference here. I'm just running the example query from the starter repo:
/**
* @name Empty block
* @kind problem
* @problem.severity warning
* @id javascript/example/empty-block
*/
import javascript
from BlockStmt b
where b.getNumStmt() = 0
select b, "This is an empty block."
It would be nice if we could get the counts for the default table, but I'm not sure how easy this is without loading the sarif.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. And is working for me.
Can you squash and rebase your commits? |
bca5000
to
bda80c2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
3e3a405
to
719d5c9
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the quick turnaround.
This pull request addresses #767 by introducing three ways of sorting the query history view - by a query's label, by the date the query was run, and by the number of results the query produced.