troubleshooting Question

how to pass parameters to an SP using select command

Avatar of Mahesh Yadav
Mahesh YadavFlag for India asked on
Microsoft SQL Server 2008
5 Comments1 Solution273 ViewsLast Modified:
I have a SP and  I am trying to call it and trying to send the parameter using a select command  

right now i am getting this error when i run the below sql statements

Msg 201, Level 16, State 4, Procedure AddPropertyProfit, Line 0
Procedure or function 'AddPropertyProfit' expects parameter '@PropertyID', which was not supplied.

(1 row(s) affected)

could any one help me out here pls


EXECUTE AddPropertyProfit
 SELECT '1981' AS PropertyID,
      'Listing' AS  [PropertyProfitType]
      ,@ID  output
      FROM PropertyProfit
      WHERE PropertyProfitID = 5
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 5 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 5 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros