Sivakumar

Sivakumar

  • NA
  • 551
  • 218.4k

How to add table to stored procedure

Aug 27 2015 6:42 AM
Hi,
 
this is my table structure :
 
 
 
and this is my stored procedure :
 
ALTER PROCEDURE [dbo].[uspGetAllTeamMembers](@TeamID INT)

AS

BEGIN


SELECT

tm.TeamID,
m.MemberID,

m.MemberName,

m.MemberStatus,

ml.MemberLoginName,
ml.MemberLoginID,

tm.MemberJoinedDate,

tm.MemberLeftDate


FROM TeamMember tm

INNER JOIN MemberLogin ml

ON tm.MemberLoginID = ml.MemberLoginID

INNER JOIN Member m

ON m.MemberID = ml.MemberID


WHERE tm.TeamID = @TeamID


END
 
so i want to add another table Team to this stored procedure to get the TeamStatus values=1
 
please give a help

Answers (1)