・SQLの中を都度書き換えないですむので便利!
実装例
declare @start int;
declare @end int;
SET @start = 20220201;
SET @end = 20220228;
SELECT * FROM SampleData WHERE updatedate BETWEEN @start AND @end
参考
https://docs.microsoft.com/ja-jp/sql/t-sql/language-elements/declare-local-variable-transact-sql?view=sql-server-ver15