cancel
Showing results forย 
Search instead forย 
Did you mean:ย 

Is there any way to set variables to before executing snowflake statement

erkonline
New Contributor

I would like to execute the 2 set variable statements before executing the select * from viewname. This view internally uses VAR1 and VAR2 variables.

set VAR1 = โ€˜ABCโ€™;
set VAR2 = โ€˜XYZโ€™;
Select * from dbname.schemaname.viewname ;

Is there anyway to set variables before executing select statement

1 REPLY 1

diptipatel_fm
New Contributor

Hi, have you found a way to do this and use this variable in execution