Show only tracked commits
This commit is contained in:
parent
476fd84d2d
commit
33ca3207e7
2 changed files with 5 additions and 2 deletions
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"db_name": "SQLite",
|
||||
"query": "WITH measurements AS ( SELECT hash, value, MAX(start) FROM runs JOIN run_measurements USING (id) WHERE name = ? GROUP BY hash ) SELECT value FROM commits LEFT JOIN measurements USING (hash) ORDER BY unixepoch(committer_date) ASC, hash ASC ",
|
||||
"query": "WITH measurements AS ( SELECT hash, value, MAX(start) FROM runs JOIN run_measurements USING (id) WHERE name = ? GROUP BY hash ) SELECT value FROM commits LEFT JOIN measurements USING (hash) WHERE reachable = 2 ORDER BY unixepoch(committer_date) ASC, hash ASC ",
|
||||
"describe": {
|
||||
"columns": [
|
||||
{
|
||||
|
|
@ -16,5 +16,5 @@
|
|||
true
|
||||
]
|
||||
},
|
||||
"hash": "9f70a2d2932837e4fcd927bcc56d9bd72a8341511486d2c0e6612f4eed2b4b95"
|
||||
"hash": "75264d014081dd190d880b89b415cecfd70dec9b56905027e27455c1dd4db02e"
|
||||
}
|
||||
|
|
@ -75,6 +75,8 @@ pub async fn get_graph_data(
|
|||
times.push(row.committer_date.unix_timestamp());
|
||||
}
|
||||
|
||||
// TODO Somehow sort topologically if committer_date is the same
|
||||
// TODO Overhaul indices once I know how the query looks
|
||||
let mut metrics = HashMap::new();
|
||||
for metric in form.metric {
|
||||
let values = sqlx::query_scalar!(
|
||||
|
|
@ -90,6 +92,7 @@ pub async fn get_graph_data(
|
|||
SELECT value \
|
||||
FROM commits \
|
||||
LEFT JOIN measurements USING (hash) \
|
||||
WHERE reachable = 2 \
|
||||
ORDER BY unixepoch(committer_date) ASC, hash ASC \
|
||||
",
|
||||
metric,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue