Snowflake Scripting 101: Blocks in Snowflake Scripting

Harness the full potential of Snowflake scripting to streamline data operations and automate complex business logics. Dive into this practical guide to discover how scripting blocks transform your Snowflake scripting experience, enabling: Precise control over data flows Optimized conditional logic Efficient looping structures Custom error handling And more! Page Content Understanding Blocks Structure of Block in a Snowflake Scripting Types of Blocks in Snowflake Scripting Common Block Use Cases Advanced Block Techniques Conclusion Understanding Blocks in Snowflake Scripting In Snowflake Scripting, blocks serve as essential building blocks for organizing and…

Comments Off on Snowflake Scripting 101: Blocks in Snowflake Scripting

How to Create Synonyms in Snowflake – Alternate Method

Relational databases utilize synonyms to conveniently assign names to lengthy tables, view names, or other objects like sequences, procedures, functions, and materialized views. Netezza and Oracle databases offer support for creating and managing synonyms. Synonyms serve as an alternative means of referencing tables or views within the current or other databases. However, Snowflake database presently lacks support for creating synonyms. In this article, we will explore an alternative method that resembles create synonyms in Snowflake. Page Content Introduction Understanding Synonyms in Databases Does Snowflake support Create Synonyms? Alternate Method for…

Comments Off on How to Create Synonyms in Snowflake – Alternate Method

How to Get Rows Affected by Last Snowflake SQL Query?

Databases such as Teradata (BTEQ), SQL Server, etc., allows you to get rows affected by the last DML statement using system variables. For example, ACTIVITY_COUNT in Teradata BTEQ. The row count of the last SQL query allows you to identify if there was any activity on table. Snowflake scripting provides system variables that hold the information of rows or records affected by an INSERT, UPDATE or DELETE queries in the current session. In this article, we will check how to get rows affected by last Snowflake SQL Query. How to Get Rows Affected…

Comments Off on How to Get Rows Affected by Last Snowflake SQL Query?

How to Use Translate Function in Snowflake?

The Snowflake TRANSLATE function returns a string with all occurrences of each character in a string replaced by its corresponding character in the replacement string. For example, you can use Snowflake translate function to replace '#' with a '@' symbol and remove '$' from input string in one operation. The translate is one of the commonly used Snowflake string functions. In this article, we will check how to use the Translate function in the Snowflake cloud database. Snowflake Translate Function Example Translate Function in Snowflake As discussed in the previous example,…

Comments Off on How to Use Translate Function in Snowflake?

Replace Function in Snowflake – Usage and Examples

The Replace function in Snowflake is one of the commonly used functions in string manipulations. For example, you can use the replace function to remove the unwanted or junk characters from your string. This function is similar to the translate function available in Snowflake. We will discuss about translate function in another post. For now, let us continue with the replace function, its syntax and some examples. Replace Function in Snowflake Replace Function in Snowflake In general, replace function in SQL replaces each instance of a pattern in the input…

Comments Off on Replace Function in Snowflake – Usage and Examples