• Why are you using IN and not = for these comparisons?

    SV00300.CUSTNMBR in (@CUSTNMBR)

    or SV00300.LOCATNNM in (@LOCATNNM)

    or SV00300.Contract_Number in (@Contract_Number)

    If any of these variables are a comma-delimited list, they won't be resolved by SQL Server in the way you are expecting. You'll need to rework the code to resolve the items in the list or alternatively use dynamic SQL.

    “Write the query the simplest way. If through testing it becomes clear that the performance is inadequate, consider alternative query forms.” - Gail Shaw

    For fast, accurate and documented assistance in answering your questions, please read this article.
    Understanding and using APPLY, (I) and (II) Paul White
    Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden