Skip to content

Conversation

@geooo109
Copy link
Collaborator

@geooo109 geooo109 commented Feb 4, 2025

This PR adds support:

  1. For default initialization of both input parameters and declared variables (e.g. CREATE PROCEDURE test(@input INT = 1, DECLARE @var AS INTEGER = 1)
  2. The OUTPUT/OUT/READONLY keywords, which primarily serve to return scalar values or enforce immutability (e.g. CREATE PROCEDURE test(@out_var INT OUTPUT))

DOCS
T-SQL Stored Procedures Paramaters

@geooo109 geooo109 requested review from VaggelisD and georgesittas and removed request for georgesittas February 4, 2025 17:31
Copy link
Collaborator

@VaggelisD VaggelisD left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, left a couple comments 👍

@geooo109 geooo109 force-pushed the geooo109/tsql_support_init_and_output branch from 1a611be to ff27776 Compare February 5, 2025 15:47
@geooo109 geooo109 requested a review from VaggelisD February 5, 2025 15:48
Copy link
Collaborator

@georgesittas georgesittas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor comment, LGTM otherwise.

@georgesittas georgesittas merged commit 707d45e into main Feb 5, 2025
7 checks passed
@georgesittas georgesittas deleted the geooo109/tsql_support_init_and_output branch February 5, 2025 18:42
CrispinStichartFNSB added a commit to CrispinStichartFNSB/sqlglot that referenced this pull request Jul 15, 2025
georgesittas pushed a commit that referenced this pull request Jul 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants