Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
dhinasql
Posting Yak Master
195 Posts |
Posted - 2008-03-07 : 10:46:04
|
| Hi Friends,I Have a Query in this SQL Query I want to check the delete field is should be 0SELECT ut.TypeName Usertype , COUNT(u.UserTypeID) Number FROM lkusertype AS ut LEFT JOIN Usermgmt AS u ON u.UserTypeID = ut.TypeID GROUP BY ut.TypeID, ut.TypenameHere i want to use where ut.deleted=0Please help me to modify this query |
|
|
harsh_athalye
Master Smack Fu Yak Hacker
5581 Posts |
Posted - 2008-03-07 : 10:49:52
|
| [code]SELECT ut.TypeName Usertype ,COUNT(u.UserTypeID) Number FROM (select * from lkusertype where deleted=0) AS ut LEFT JOIN Usermgmt AS u ON u.UserTypeID = ut.TypeID GROUP BY ut.TypeID, ut.Typename[/code]Harsh AthalyeIndia."The IMPOSSIBLE is often UNTRIED" |
 |
|
|
|
|
|