Templat Help - Select columns from a table not referenced

Hello Everyone,

I'm trying to create an on demand report usind a dynamic dashboard and a button with a NOW() trigger. The intention is to get delivery info (group "Bairro" column) from Order Table based on what is set on DashboardFilter Table and when [Frete?] column is TRUE.

This is the template format:

Thales_Taranto_0-1650833400344.png

And the Start expression that is not working is: (When i remove the highlighted text it works but do not filter if [Frete?]=TRUE. This means that it can't filter and sort only the orders that needs to be delivered. 

<<Start: ORDERBY(SELECT(Pedido[Pedido ID],AND(Pedido[Frete?]=TRUE,if(ISBLANK(Dashboard Filter[Data Pedido Inicio]),true,[Data do Pedido]>=ANY(Dashboard Filter[Data Pedido Inicio])),if(ISBLANK(Dashboard Filter[Data Pedido Fim]),true,[Data do Pedido]<=ANY(Dashboard Filter[Data Pedido Fim])),if(ISBLANK(Dashboard Filter[Data Entrega Inicio]),true,[Data Entrega]>=ANY(Dashboard Filter[Data Entrega Inicio])),if(ISBLANK(Dashboard Filter[Data Entrega Fim]),true,[Data Entrega]<=ANY(Dashboard Filter[Data Entrega Fim])))),[Bairro],FALSE)>>

 

By this method i can't extract the list of Orders that has [Frete?] values equal to TRUE, since this info is on Orders Table and the entity table of this automation is DashboardFilter. (image bellow)

 

Thales_Taranto_1-1650833518534.png

 

 

 

 

 

Solved Solved
0 5 143
1 ACCEPTED SOLUTION

Just [Frete?] in that case if it's a Y/N column

View solution in original post

5 REPLIES 5


@Thales_Taranto wrote:

Pedido[Frete?]=TRUE


This makes no sense, you are saying "The list of all [Frete?] values of the Pedido table equals true".

If you want the rows from Pedido table where Frete? is true, you should use Filter().

https://help.appsheet.com/en/articles/2357308-filter

FILTER(
  "PEDIDO",
  [Frete?]
)

Yeah but i also need to conform the Orders based on the dynamic filter dashboard (when user select a date range, it will only show orders on this range:

 

Thales_Taranto_0-1650838137309.png

 

So using only this Filter formula won't work. Is there a way to insert this filter inside the SELECT formula i made? 

 

Since the SELECT statement is against the table Pedido, wouldn't the simple  [Frete?]=TRUE work instead of Pedido[Frete?]=TRUE ?

Just [Frete?] in that case if it's a Y/N column

I tried what you suggested and it works. Thank you @SkrOYC 

Top Labels in this Space