Snowflake Vs MS-SQL - Part 94 - BOOLAND_AGG


BOOLAND_AGG

If you want to identify values that are the same as the given criteria. In the table below, all orders have an order_status of SHIPPED.

ORDER_ID  ORDER_STATUS
1         SHIPPED
2         SHIPPED
3         SHIPPED
4         SHIPPED

MS-SQL Server

We can achieve it as follows:



In Snowflake, we can use the same query as above; however, we can use BOOLAND_AGG as follows:





For more details, refer to the BOOLAND_AGG section.


Comments

Popular posts from this blog

Snowflake Vs MS-SQL - Part 70 - UNION By Name

Snowflake Vs MS-SQL - Part 68 - Multi Table Insert

Snowflake Vs MS-SQL - Part 63 - ON Clause & Cross Join