DiscussionBoard Lists in sp2010: Part 1

In SP2010, actually all discussion board lists are created with BaseType = 0 and it falls in to GenericList category. This is a bug (definitely) in SP2010.

  1. This is the reason why you could not get them when you have tried with SPSiteDataQuery and list for BaseType = 3
  2. That’s why web.GetListsOfType(SPBaseType.DiscussionBoard) will not return any list.

(SharePoint Guys pls fix this…)

Using serverTemplate=108 with SPSiteDataQuery will still retrieve items from all Discussion Board list. SPSiteDtaQuery is efficient method for retrieving list items. There are few things to keep in mind while querying Discussion Board [or say any type of list]

  • If you want to retrieve all list names of specific type (not interested in list items) choose linq to SharePoint Option.
  • If you want to retrieve data from selected lists or from all lists in the current site collection choose SPSiteDataQuery.

Hope that helps…

One thought on “DiscussionBoard Lists in sp2010: Part 1

Comments are closed.