when this stored procedure executes without this parameter, stored procedure should use the default value and if this parameter is assigned to a value, stored procedure should execute by assigned value.
when this stored procedure executes without this parameter, stored procedure should use the default
Share
Declare a variable, say
myVar. Check if the parameter is null. If it is not null you assign it tomyVarotherwise you assign the default value.