sql server - Stored Procedure Count(*) -


i have stored procedure:

create procedure [dbo].[getcorrespondingrespcode] @rc char(3) begin     set nocount on;      declare @webrccount int      select webrc, count(*) webrccount       payterm.response_codes_mapping       rc = @rc group webrc end 

how can set @webrccount value of webrccount? need if @webrccount = 1 print'ok'

select @webrccount = count(*)  payterm.response_codes_mapping  rc = @rc  select @webrccount [webrccount] 

that should it...


Comments

Popular posts from this blog

jquery - How can I dynamically add a browser tab? -

node.js - Getting the socket id,user id pair of a logged in user(s) -

keyboard - C++ GetAsyncKeyState alternative -