
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dates in set expression
I have a table like this
And I want to have a filter in my app that will have the name of the conselour (no_conselheiro) but when selected the filter will be by those dates. The dates will be in a variable, and the variable will be used to filter a card.
I have made a set expression that look like this:
=COUNT({1<ft_processos.dt_julgamento={'>=$(v_dt_inicio_mandato)'}>*<ft_processos.dt_julgamento={'<=$(v_dt_fim_mandato)'}>} ft_processos.nu_processo_sei)
The syntax is correct and the date is being captured by the variables, according to the image below
But it is returning 0 instead of the number of process that were judged in this period. When I use IF instead of set analysis I get a result, but the result is the number of processes judged by the conselour, and I need the processes that were judged in that time frame.
Any help on how can I solve this?
Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
When using >= in set analysis, you need to use double-quotes " instead of single quotes.
=COUNT({1<ft_processos.dt_julgamento={">=$(v_dt_inicio_mandato)"}>*<ft_processos.dt_julgamento={"<=$(v_dt_fim_mandato)"}>} ft_processos.nu_processo_sei)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
When using >= in set analysis, you need to use double-quotes " instead of single quotes.
=COUNT({1<ft_processos.dt_julgamento={">=$(v_dt_inicio_mandato)"}>*<ft_processos.dt_julgamento={"<=$(v_dt_fim_mandato)"}>} ft_processos.nu_processo_sei)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I got through this:
=COUNT({1} DISTINCT IF(dt_julgamento >= v_dt_inicio_mandato AND dt_julgamento <= v_dt_fim_mandato, ft_processos.nu_processo_sei))
