Unfortunately you can't send a parameter to a view. Not sure what you are trying to achieve but perhaps writing a stored procedure could do what you want.
Thanks for quick response.
I am VFP programmer. What I am trying to do is
create a View which criteria is variable, such like VFP view.
How can I do it in store procedure? Would you please guide me ?
This is a very simple stored procedure called upr_test which takes as an input parameter a of a customer number. The procedure then selects the address details from a table called ADDRESS based on this criteria.
CREATE PROCEDURE upr_test
@Customer_Num INT
AS
SET NOCOUNT ON
SELECT *
FROM ADDRESS
WHERE ADD_CUSTOMER_NUM = @Customer_Num
After the procedure has been created you can execute upr_test in the following manner where nnnnnn is the customer number of your choice.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.