[sql] -- ===================【創(chuàng)建存儲過程】===================== USE [Message] GO /****** Object: StoredProcedure [dbo].[讀取外部數(shù)據(jù)庫查詢] Script Date: 10/24/2012 05:39:16 ******/ SET ANSI_NULLS ON GO SET QUOTED_IDENTIFIER ON GO -- ============================================= \\ Working沒有變1,錯誤碼沒有測試,計劃時間測試,企業(yè)名稱 create PROCEDURE [dbo].[數(shù)據(jù)庫查詢] @SmsContent varchar(20)='1231', -- 輸入?yún)?shù) @bj1 int out -- 輸入出參數(shù) AS BEGIN SELECT @bj1=count(Id) from sss END -- ===============【調(diào)用】================== USE [Message] DECLARE @return_value int EXEC [dbo].[數(shù)據(jù)庫查詢] '1231',@return_value output SELECT @return_value