SMO DiscoverDependencies returns a tree that has infinit loop - by J S Nahil

Status : 

  Not Reproducible<br /><br />
		The product team could not reproduce this item with the description and steps provided.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.

Sign in
to vote
ID 773896 Comments
Status Closed Workarounds
Type Bug Repros 0
Opened 12/9/2012 10:53:43 AM
Access Restriction Public


I have a product that prints SQL Server schema objects. When I migrated the product to SQL Server 2012 SMO the product kept getting Stack overflow when printing object dependencies.
The problem is that DiscoverDependencies method of scripter for table 'ActiveSubscriptions' in database ReportServer returns tree that is wrong such that the child and next sibling nodes are the same. See the screenshots that I have uploaded to my website. here is the link:

Here is the link to VB.NET projects that demonstrates the bug:
Running Instructions:
1. Edit lines 18 and 21 in the Form1.vb with your own server and database names
2. Run the program and it should stop with Stack Overflow 

Can anyone please suggest a workaround this bug?
 Joginder Nahil
Sign in to post a comment.
Posted by Alex [MSFT] on 3/20/2013 at 11:25 AM

We didn't recieve any update from you on this issue, so we assume that the issue was resolved and we will go ahead and close it. You can always reactivate it later and provide more details as needed.

Thank you
Alex Grach[MSFT]
Posted by Microsoft on 2/15/2013 at 11:38 AM
Can you please give us more information about schema and dependencies between tables. Based on provided information in the dependencies chart in ( I could not repro this issue.

Fatemeh Alavizadeh
Posted by Microsoft on 2/8/2013 at 12:30 PM
Thank you for reporting this issue.
We are investigating and will update you when we have more information.

Fatemeh Alavizadeh [MSFT SQL SERVER]