Skip to content
Advertisement

Tag: snowflake-cloud-data-platform

Create an array in Snowflake

I want to create an array constructed from two timestamps. After that, use this as a range to find the difference between the first element and the second element. The goal is to find the time difference between timestamps within business hours (9 am to 17 pm). What should be the right approach here? Can I create arrays and then

Snowflake unsupported subquery when using function

This is the function I created: I’m using the ROW_NUMBER function because the RATE_DATE field is actually datetime and so there are multiple records per date. When I call the function by itself, it works fine. However, when I try to use it in a view, I get the unsupported subquery type error. The view works fine without it. Can

Not able to resolve “Numeric Value ‘-‘ is not recognized” error in Snowflake SQL Query

I’m working on converting the sql query below over to Snowflake, and got the error “Numeric Value ‘-‘ is not recognized” but it did not have a line number. I assume it’s in reference to the various “-1” instances throughout the query but there’s no line referenced so it’s unclear what’s causing the problem. If it’s the various references to

Advertisement