CREATE FUNCTION Person_Details (@P_ID int)
RETURNS TABLE
AS
RETURN(SELECT Person_ID,P_F_Name
FROM Person_tbl
WHERE Person_ID=@P_ID)
SELECT dbo.Person_Details(1)
--WHAT SHOULD I DO HERE BECAUSE IM STILL A NEWBIE
答案 0 :(得分:1)
尝试:
SELECT * FROM dbo.Person_Details(1)