TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Sivakumar
NA
551
218.3k
How to get count of values in stored procedure
Mar 8 2016 1:51 AM
Hi,
I want to get count of Job status like count of open,count of closed jobs and count of processing jobs
This is my procedure :
USE [SmartJob
GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER PROC [dbo].[GetJobStatus]
@CompanyID INT
AS
BEGIN
SELECT [StatusID]
,M.Value 'Status' FROM Jobs J
JOIN Master M ON M.MasterID=J.StatusID
WHERE CompanyID=@CompanyID;
END
Please help me
Reply
Answers (
4
)
how to count group by in sql server
Use of ADO.Net and its function