Tech
Forums
Jobs
Books
Events
Live
Interviews Prep
More
Learn
Training
Career
Members
Videos
News
Blogs
Login
Sign Up
Ask Question
1
Reply
multiple select statements
Bindu
Nov 5 2012 7:13 AM
1.1k
Reply
Hi...
my stored procedure is
select count(TaskId) as tasks from Task T,Provider P where P.UserId=T.UserId and T.permissions='False' and T.State='Close' and T.Assignedto=@Assignedto
select count(TaskId) as tasks1 from Task T,Provider P where P.UserId=T.UserId and T.Permissions='False' and T.State='Open' and T.Assignedto=@Assignedto
select count(TaskId) as tasks2 from Task T,Provider P where P.UserId=T.UserId and T.Permissions='False' and T.State='Completed' and T.Assignedto=@Assignedto
it is working in sql. but when i am using it in services i am getting only tasks value.i can't get tasks1 and tasks2. where i am going i cant under stand. is there another way to write this stored procedure.
thanks in advance....
Upload Source Code
Select only zip and rar file.
Post
Reset
Cancel
Answers (
1
)
Next Recommended Forum
Quoted_ident0ifier on SQL
For loop in Sql Server