.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

hierarchyid - any thoughts on grouping children across multiple parents

Posted By:      Posted Date: October 02, 2010    Points: 0   Category :Sql Server

Hey there,

I have just been playing around with the hierarchyid examples on MSDN and came across this issue in my experiments and wondered whether anyone has any thoughts on creating some sort of "grouping" of child nodes across different parents:

If I have the following two tree items:



The two DVD nodes aren't associated by anything other than a common title which makes it difficult to search for all DVDs so you could change the structure to this:


but then the problem rears it's ugly head in the same fashion when you add more data:


Now there are two Music and Movie nodes that are loosely associated by a common title.


I am not suggesting that the hierarchyid should be able to represent data like this and it is still useful for strictly hierarchical models I just wondered whether anyone had come up with a solution that overcomes this problem. My initial thoughts are that you could

View Complete Post

More Related Resource Links

Multiple Values Grouping

Hi all, Please could you help to get multiple values grouping implemented properly? I need to group a set of instances by groups. Some instances belong to multiple groups. I have used listbox and GroupDescriptions for that. Those instances that belong to several groups are shown as duplicates (like in Outlook when letter belongs to several categories). But selection of items becomes buggy. Even if ListBox SelectionMode is Single, it is possible to get two different items (not duplicates) to be selected simultaniously. Please use my code example. Launch application Put check into checkbox to apply grouping. Select Potato(Tasty). Select Tomato(Round). Select Potato(Tasty). Select Tomato(Round). Notice that Potato(Tasty) and Tomato(Round) are selected simultaniously.   <Window x:Class="GroupingSample.Window1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="Grouping Sample" Width="220" Height="550"> <StackPanel> <TextBlock Margin="12,5,5,0" FontSize="20" Text="My Task List"/> <CheckBox Margin="10,5,5,10" Checked="AddGrouping" Unchecked="RemoveGrouping">Group by task type</CheckBox> <ListBox Margin="10&qu

How to implement Bounding Box(Multiple selection of objects) and grouping as implemented in Photosho

Hello Everybody, I am working on Winform with SVG,PVG(these are the format used ofr WPF, not using XAML) for a Publishing application. I want to implement the multiselect of different objects and scaling to them and also grouping them and implementing rotating and moving and sacling the objects as group . I want the exact/some pont near to what photoshop/Scribus has implemented in their application. Thanks, Himanshu

Many Parents Many Children relationship


OLAP - I have in RDBMS(Data Warehouse) -  ParentId and ChildId are TypeId's

ParentId and ChildId have many to many relationship. One parent can have many children(TypeIds) and same way One ChildId can have multiple parents(TypeIds)

Table A
TypeId (PK)

Table B

TypeId (FK)

How will I design a OLAP solution for these tables - what are my dimension and its hierarchy?

I want to display for All Parents->All Children->Measure(Values), DateTime


Grouping by "multiple choices" column



This is for Sharepoint 2010

In a document library, I am trying to create a view that would group files by "projects". A file could be part of multiple projects.

file1.doc : projectA, projectB
file2.doc : projectB
file3.doc : projectB, projectC

I would like the view to show things this way :


By default Sharepoint does not allow grouping by "multiple choices" columns. However it seems that using sharepoint designer this could be done. I could only find articles on how to do this in MOSS 2007 but not MOSS 2010 (http://blog-sharepoint.blogspot.com/2009/09/solved-cant-group-by-choice-column-in.html).

Any suggestion on how I could achieve my goal with sharepoint designer 2010 ?


Thank you


Need Help - Grouping multiple fields to get top 10 for month then using that data to get previous mo



I’m querying a database in BIDS using SQL 2005 to produce a report in SSRS. All the information I need is in one table.

The table has 3 columns. The data within each column can be identical but when the 3 columns are grouped together they make up a unique set.

For example:
Month     Col 1     Col2       Col3
201009   Field A   Field B   Field C
201009   Field A   Field B   Field D

201009   Field A   Field B   Field D

201009   Field A   Field E   Field C
201009   Field B   Field B   Field F

201009   Field B   Field B   Field F
201009   Field B   Field G   Field G
201009   Field C   Field B   Field F

I need to count the number of times these unique sets appear each month and produce a report showing the to

TreeView with parent to single child relation from multiple children c#



how to populate treeview  with a child node and with all its parent nodes





       -----a11 // if selected i want to draw treeview with its all parents






Custom Control: Multiple children, "{0} can accept only one child."


Long story short - I'm trying to build a custom accordion control that in essence is a Scroll Viewer wrapped around a Stack Panel.  Once I get past the hump I'm at now which is getting the custom control to accept multiple children I should have no further issues.  


Below is my style for the control:


  <Style TargetType="{x:Type local:ScrollableAccordion}">
    <Setter Property="Template">
        <ControlTemplate TargetType="{x:Type local:ScrollableAccordion}">
          <Border Background="{TemplateBinding Background}"
              BorderBrush="{TemplateBinding BorderBrush}"
              BorderThickness="{TemplateBinding BorderThickness}">
          <ScrollViewer Height="{TemplateBinding Height}"
                 Width="{TemplateBinding Width}"

Create multiple graphs by Grouping/


so I have a line graph- costs on the x axis-two categories on the y axis-the first is unit- we have 10 of these- the scond is month of the year- there are 12 of these. I also have a calculates series of a moving average.  I have a parmater to first select the unit ( its a multiple parameter) also  parameter for the year.

What I need the graph to do is create a new graph for every three units selected- if not the graph is unreadable. I know there is a way to do this but can't seem to get it to work



Multiple database support with Entity Framework

One of the features introduced in Entity Framework is being database independent. Which mean each database provider can support Entity Framework by implementing its provider.

This feature allows you build applications independent from the underplaying database provider. In this post I'm going to show how to build an application that support multiple databases using same conceptual model made by Entity Framework.

Playing with Linq grouping: GroupByMany?

One of its features is grouping. Many people understand grouping like it is defined in Sql. Linq is implementing grouping quite the same way. Let's discover this syntax and how to make consecutive groups easier.

Grouping Gridview with jquery

The requirement of the project is to show a table of data with the riskdetails(just for assumption) which have the corresponing values for every month and people used to compare the values for last months.

Binding the multiple drop down boxes in GridView using JQuery in ASP.NET

Here is the code for binding the multiple drop down boxes in GridView using JQuery in ASP.NET

Building a grouping Grid with GridView and ASP.NET AJAX toolkit CollapsiblePanel

I've posted an update to this post to apply on demand loading of Details data using ASP.NET AJAX PageMethods. I'm demonstrating the usage if CollapsiblePanelExtender client events on the new post. Check it out.

I admit, Matt Berseth is really inspiring me! Few days ago I pass through 2 of his great posts:

.Surrounding your Data Table and Dialog Controls with ComponentArt Styled Panels
.Building a Grouping Grid with the ASP.NET 3.5 LinqDataSource and ListView Controls
The first one is pure design tips one which I used for making good presentation of my demo here. The 2nd post is actually the idea.

Upload Multiple File using JQuery in asp.net

In this article I have explained how to upload multiple files using file upload control. I have used jQuery plugin for uploading multiple files.

I have also explained how to check for file type, file maximum size limit using jQuery & also using server side validation code.

Grouping Gridview with jquery in asp.net

The requirement of the project is to show a table of data with the riskdetails(just for assumption) which have the corresponing values for every month and people used to compare the values for last months.

Adding Multiple Columns and Rows in GridView without using a Database

This article describes on how to add multiple columns and rows in GridView without using a database. Basically the GridView will be populated with data based on the values entered in each TextBoxes on Button Click and retain the GridView data on post back.

GridView Multiple Filter AJAX Control

This AJAX control enables the user to filter data within any column inside a GridView. The user can add multiple filters and can delete existing ones too.
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend