• As the User Define table Types are created as table-valued, so you cannot assign null to a table.

    2ndly if you want to check if there is any value in the variable then you can use the following:

    Place the following code after the scope_identity()

    IF EXISTS ( Select 1 from @skills)

    Begin

    -- Add your code here

    End

    Hope it helps.