thinQmaster Virtual testing partner Adaptive practice exams that find your weak spots and drill them. Every answer explained. From $69
Enroll

thinQmaster

Find your exam

Five questions free, before you decide.

Step 1 · choose a vendor

In one of our camps? Your practice exams come with the tuition — they are on your study page already.

Data & Analytics · Intermediate

Stored Procedure

A named, precompiled set of SQL (and procedural) statements stored in the database and executed with CALL or EXEC.

Definition

Stored procedures encapsulate business logic, accept parameters, can return result sets or output values, and can contain transaction control. They reduce network round trips and support security by granting EXECUTE without table access. Snowflake procedures can be written in SQL (Snowflake Scripting), JavaScript, Python, Java or Scala.

Example

EXEC usp_RefreshDailySales @RunDate = '2026-11-01';

Exam tip

Procedures can modify data and manage transactions; functions are generally meant to return values and be used inside queries.

Related terms