Skip to content
quarry Artifact [e2c70559da]
Login

Artifact [e2c70559da]

Artifact e2c70559da319297c252bcabee97b75a3e19465ba1b8aa56eecb9a61618585a7:

Ticket change [e2c70559da] - New ticket [aa28c880b6] Ticket reports: saved, named queries over the tracker. by dmestas on 2026-08-18 21:06:50.
D 2026-08-18T21:06:50.777
J cmimetype text/x-markdown
J comment The\slargest\sgap\sagainst\sfossil.\sA\stracker\sof\sany\ssize\sis\sunusable\swith\sone\slist:\stk\sholds\s5,809\stickets,\ssqlite\s1,637.\sWhat\speople\sactually\swant\sis\s"my\sopen\stickets",\s"severity>=Critical\sin\ssubsystem\sX",\s"closed\ssince\sthe\slast\srelease".\n\n##\sHow\sfossil\sdoes\sit\n\nA\s`reportfmt`\stable\sin\sthe\srepository\sholds\ssaved\sreports:\s`rn`\s(integer\skey),\s`title`,\s`owner`,\s`sqlcode`,\s`cols`,\s`mtime`,\sand\sa\s`jx`\sJSON\scolumn\scarrying\sa\s`tag`\sfor\sstable\snaming.\sSurfaces\sare\s`/reportlist`,\s`/rptview`,\s`/rptnew`,\s`/rptedit`,\s`/rptsql`.\sA\sreport\sis\saddressable\sthree\sways\s—\sby\s`rn`,\sby\stitle,\sand\sby\s`jx->>tag`.\n\nThe\sreport\sbody\sis\sliteral\sSQL\sagainst\sthe\sTICKET/TICKETCHNG\stables.\sColumn\snaming\sdrives\spresentation:\sa\scolumn\snamed\s`bgcolor`\scolours\sthe\srow\srather\sthan\sbeing\sdisplayed.\n\n##\sWhat\squarry\smust\sNOT\scopy\n\nStoring\suser-authored\sSQL\sand\sexecuting\sit.\sFossil\scan\sdo\sthis\sbecause\sits\sreports\sare\sadmin-authored\sconfig\son\sa\srepository\sthe\sadmin\salready\scontrols.\squarry\sserves\s23\sstores\sfrom\sone\sprocess\swith\sone\sindex\shandle\seach;\sarbitrary\sSQL\sfrom\sa\sform\sis\sa\sread-anything\sprimitive\sacross\sa\sshared\ssurface,\sand\s`ATTACH`,\s`pragma`\sand\s`load_extension`\sare\sall\sreachable\sfrom\sa\sSELECT.\n\n##\sRecommended\sshape\n\nA\s**structured\sfilter**,\snot\sSQL:\n\n-\sPredicates\sover\sindexed\sticket\sfields:\sfield,\soperator\s(is\s/\sis-not\s/\scontains\s/\sbefore\s/\safter),\svalue.\sAND-ed,\swhich\scovers\sessentially\severy\sreal\sreport.\n-\sSort\sfield\sand\sdirection.\n-\sPersisted\sper\srepository\sin\sthe\sforge\sOLTP\s(`ticket_report`:\srepo,\stag,\stitle,\sowner,\sspec\sJSON,\smtime),\sNOT\sin\sthe\sindex\s—\sa\sreport\sis\sauthored\sstate,\snot\sderived,\sso\s0001\s§11\ssays\sit\smay\snot\slive\ssomewhere\swipeable.\n-\sCompiled\sto\sparameterised\sSQL\sby\squarry.\sThe\suser\schooses\sfields\sand\soperators\sfrom\swhat\sthe\sschema\sactually\shas;\sthey\snever\ssupply\ssyntax.\n\nThis\sis\sstrictly\sless\sexpressive\sthan\sfossil\sand\scovers\sthe\sreal\scases.\sIf\sa\sgenuine\sgap\sappears\slater,\sthe\sanswer\sis\smore\soperators,\snot\san\sSQL\sbox.\n\n##\sSurfaces\n\n-\s`report.list`,\s`report.get`,\s`report.save`,\s`report.delete`\sops;\sthe\squery\sitself\sis\s`ticket.list`\swith\sa\sspec.\n-\s`/r/{repo}/ticket?report=TAG`,\sand\sa\sreport\spicker\sbeside\sthe\sopen/all\stoggle.\n-\sReport\sauthoring\sgated\sat\swrite\son\sthe\srepository,\smatching\sfossil\sadmin-only\sreports.\n\n##\sDepends\son\n\nNothing.\sThis\sis\spure\sread\sover\sthe\sfolded\s`ticket`\sand\s`ticket_field`\stables\sthat\salready\sexist.\s`ticket_field`\swill\swant\san\sindex\son\s`(name,\svalue)`\sfor\spredicate\spushdown;\smeasure\sbefore\sadding\sit.
J severity Important
J status Open
J title Ticket\sreports:\ssaved,\snamed\squeries\sover\sthe\stracker
J type Feature_Request
K aa28c880b6097f5719e25e1af188244e71507c38
U dmestas
Z 5719123bb69b62e3ea1d6692ae629b74