You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Like in all SQL groupings, you must include the parameter in both the `SELECT` and `GROUP BY` clauses. You can also use the `mb.time_grouping` function on different columns in the same query, like this:
39
39
40
40
```sql
41
+
{% raw %}
41
42
SELECT
42
43
COUNT(*) AS"Count",
43
44
{{created_at_param}} AS"Created at",
@@ -47,6 +48,7 @@ FROM
47
48
GROUP BY
48
49
{{created_at_param}},
49
50
{{trial_ends_at}}
51
+
{% endraw %}
50
52
```
51
53
52
54
Like with all parameters, you can set a default value (e.g., "month"). With time grouping parameters, you're limited to the options for the [time grouping parameter](../../dashboards/filters#time-grouping-parameter).
<p>Like in all SQL groupings, you must include the parameter in both the <codeclass="language-plaintext highlighter-rouge">SELECT</code> and <codeclass="language-plaintext highlighter-rouge">GROUP BY</code> clauses. You can also use the <codeclass="language-plaintext highlighter-rouge">mb.time_grouping</code> function on different columns in the same query, like this:</p>
<p>Like with all parameters, you can set a default value (e.g., “month”). With time grouping parameters, you’re limited to the options for the <ahref="../../dashboards/filters#time-grouping-parameter">time grouping parameter</a>.</p>
0 commit comments