SQL Interview: 32 Using ALTER FUNCTION in SQL Server

SQL Interview: 32 Using ALTER FUNCTION in SQL Server

This is a post in the SQL Interview series. These aren’t trick or gotcha questions, they’re just questions designed to scope out a candidate’s knowledge around SQL Server and Azure SQL Database.

Section: Development Level: Medium

Question:

You have a scalar T-SQL function in SQL Server and want to change it.

Apart from permissions, what would stop you from using ALTER FUNCTION to change it?

Answer:

You can’t change from an inline function to a multi-statement function.

2025-03-29