Is there a way to turn this query to regular inline SQL

Posted by Luke101 on Stack Overflow See other posts from Stack Overflow or by Luke101
Published on 2010-04-19T05:27:51Z Indexed on 2010/04/19 5:33 UTC
Read the original article Hit count: 329

Filed under:
|

I would like to turn this query to regular inline sql without using stored procedures

declare @nod hierarchyid
select @nod = DepartmentHierarchyNode
from Organisation
where DepartmentHierarchyNode = 0x6BDA

select * 
from Organisation
where @nod.IsDescendantOf(DepartmentHierarchyNode) = 1

Is there a way to do it?

© Stack Overflow or respective owner

Related posts about sql-server-2008

Related posts about c#