UDF Function Parameter Pass

Posted on 2011-10-28
Last Modified: 2012-05-12
I have a UDF that requires 4 parameters (variables). I am just starting to work with these (UDF's) so I thought I could implement them the same as a Stored Proc. I tried an EXEC udf (paramenter 1, parameter 2, parameter 3, parameter 4). I find that is not the way to do it. So how can I use this UDF and how do I pass it the parameters?
Question by:SeTech
    LVL 15

    Accepted Solution

    Use select instead of EXEC and make sure you put the schema name in front of the function name.

    select dbo.udf(param1, param2)
    LVL 14

    Expert Comment

    here is the answer to your question

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Do You Know the 4 Main Threat Actor Types?

    Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

    There have been several questions about Large Transaction Log Files in SQL Server 2008, and how to get rid of them when disk space has become critical. This article will explain how to disable full recovery and implement simple recovery that carries…
    How to leverage one TLS certificate to encrypt Microsoft SQL traffic and Remote Desktop Services, versus creating multiple tickets for the same server.
    Sending a Secure fax is easy with eFax Corporate ( First, Just open a new email message.  In the To field, type your recipient's fax number You can even send a secure international fax — just include t…
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

    760 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    15 Experts available now in Live!

    Get 1:1 Help Now