<div dir="auto"><div>Bump, sorry...<br><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">A segunda, 22/06/2020, 11:06, Alexandre Neto <<a href="mailto:senhor.neto@gmail.com">senhor.neto@gmail.com</a>> escreveu:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<br><div><br></div><div><b><u>TL;DR;</u></b></div><div><br></div><div>Would it be ok to add a group key in the function help JSON files? Something like this:<br><br><table style="border-spacing:0px;border-collapse:collapse;color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";font-size:14px"><tbody style="box-sizing:border-box"><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-LC1" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">{</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L2" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC2" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">  "name": "array_agg",</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L3" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC3" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">  "type": "function",
 <b> <font color="#0000ff">"group": "Aggregates",</font></b></td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L4" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC4" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">  "description": "Returns an array of aggregated values from a field or expression.",</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L5" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC5" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">  "arguments": [</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L6" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC6" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">    {"arg": "expression", "description": "sub expression of field to aggregate"},</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L7" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC7" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">    {"arg": "group_by", "optional": true, "description": "optional expression to use to group aggregate calculations"},</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L8" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC8" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">    {"arg": "filter", "optional": true, "description": "optional expression to use to filter features used to calculate aggregate"},</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L9" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC9" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">    {"arg": "order_by", "optional": true, "description": "optional expression to use to order features used to calculate aggregate"}</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L10" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC10" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">  ],</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L11" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC11" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">  "examples": [</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L12" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC12" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">    { "expression": "array_agg(\"name\",group_by:=\"state\")", "returns":"list of name values, grouped by state field"}</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L13" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC13" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">  ]</td></tr><tr style="box-sizing:border-box"><td id="m_-5330327972267598787gmail-L14" style="box-sizing:border-box;padding:0px 10px;width:50px;min-width:50px;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;line-height:20px;color:rgba(27,31,35,0.3);text-align:right;white-space:nowrap;vertical-align:top"></td><td id="m_-5330327972267598787gmail-LC14" style="box-sizing:border-box;padding:0px 10px;line-height:20px;vertical-align:top;overflow:visible;font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,monospace;font-size:12px;white-space:pre-wrap">}</td></tr></tbody></table></div><div><br></div><div><b><u>WHY</u></b></div><div><br></div><div>I am following Thomas Grattier effort to put all expression functions in a single HTML page:</div><div><br></div><div><a href="https://gist.githack.com/ThomasG77/0c6862fb2b6b3fc301ea994733688ea5/raw/99ecc5e6127e7238814da330a4d5d0b9fa2afe4e/qgis-3-12-expressions-single-page.html" target="_blank" rel="noreferrer">https://gist.githack.com/ThomasG77/0c6862fb2b6b3fc301ea994733688ea5/raw/99ecc5e6127e7238814da330a4d5d0b9fa2afe4e/qgis-3-12-expressions-single-page.html</a><br></div><div><br></div><div>This is how he did it:</div><div><br></div><div><a href="https://gist.github.com/ThomasG77/0c6862fb2b6b3fc301ea994733688ea5" target="_blank" rel="noreferrer">https://gist.github.com/ThomasG77/0c6862fb2b6b3fc301ea994733688ea5</a><br></div><div><br></div><div>This made me think that would be great to have a complete list like this on our documentation. But, unfortunately we can't use his approach which generates HTML</div><div><br></div><div><span style="color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";font-size:14px">My idea would be to use the JSON files in QGIS\QGIS to </span>semi-automagically<span style="color:rgb(36,41,46);font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";font-size:14px"> populate the function list with Sphinx format files. Which would be much easier to do, if there is a group key in each function.</span><br></div><div><br></div><div><a href="https://github.com/qgis/QGIS-Documentation/issues/5747" target="_blank" rel="noreferrer">https://github.com/qgis/QGIS-Documentation/issues/5747</a><br></div><div><br></div><div>Thanks,</div><div><br></div><div>Alexandre Neto</div></div>
</blockquote></div></div></div>