SharePoint Content Database简介
SharePoint作为微软主打的企业Portal平台,功能强大,使用简单,非常的方便。对于很多关系数据,我们可以使用自定义列表来维护,如果是非关系数据,可以使用文档库来维护。另外还可以在上面进行版本维护,工作流审批,而这一切可以不用写一行代码,只需要在界面和SharePoint Designer中进行设置即可完成。
虽然SharePoint很简单,很容易上手,但是对于开发人员来说,维护在其中的数据又怎么和其他系统进行集成呢,我们可以使用3种方法:
- 在SharePoint Server使用C#程序,调用SharePoint对象模型,读取其中的各种数据。
- 在客户端调用SharePoint的WebService,读取其中的数据。
- 直连SQL Server SharePoint Content数据库,使用SQL来读取其中的数据。
前面两种方法,都是官方推荐的,文档详细,介绍较多,我就不讲了,我接下来主要研究如何直接读取SharePoint Content DB的数据。微软官方肯定是不推荐使用这种方法的,因为这个太底层了,完全脱离了SharePoint的控制,如果对其中数据进行直接的修改,那么可能会产生SharePoint无法预期的数据值。不过做数据库应用开发的都明白,这种方法执行效率最高,灵活性最大。为了避免写入无法预期的数据导致SharePoint崩溃,所以我们只是读取SharePoint Content DB,不做任何Update和Delete操作。要读取SharePoint Content DB的数据,首先要对其表结构做给基本的了解。
从网上(http://blogs.technet.com/b/praveenh/archive/2010/12/20/inside-a-sharepoint-content-db.aspx)找的一个简介的表格,介绍了主要的几个SharePoint Content DB Table:
| Features | Table that holds information about all the activated features for each site collection or site. |
| Sites | Table that holds information about all the site collections for this content database. |
| Webs | Table that holds information about all the specific sites (webs) in each site collection. |
| UserInfo | Table that holds information about all the users for each site collection. |
| Groups | Table that holds information about all the SharePoint groups in each site collection. |
| Roles | Table that holds information about all the SharePoint roles (permission levels) for each site. |
| All Lists | Table that holds information about lists for each site. |
| GroupMembership | Table that holds information about all the SharePoint group members. |
| AllUserData | Table that holds information about all the list items for each list. |
| AllDocs | Table that holds information about all the documents (and all list items) for each document library and list. |
| RoleAssignment | Table that holds information about all the users or SharePoint groups that are assigned to roles. |
| Sched Subscriptions | Table that holds information about all the scheduled subscriptions (alerts) for each user. |
| ImmedSubscriptions | Table that holds information about all the immediate subscriptions (alerts) for each user. |
另外再配上了一个图,说明其中的关系。
![]()
其中最最重要的就是AllUserData这个表,我们可以从微软MSDN找的一些对几个核心表的介绍:
http://msdn.microsoft.com/en-us/library/hh625524(v=office.12).aspx
这个文档介绍的是最新的SharePoint2013的数据库结构,如果使用SharePoint2010或者07也不用担心,大部分字段都是一样的。如果SharePoint2003,还可以参考官方的另一个文档:
http://msdn.microsoft.com/en-us/library/dd587562(v=office.11).aspx
当然,仅仅有这么几个表还不够,在实际使用中,我们还需要关联其他的表进行联合查询,才能完成我们想要的东西。接下来我会写几个Case,一个一个的分析如何查询对应的表。
SharePoint Content Database简介的更多相关文章
- EXTRACT FILES AND IMAGES FROM A SHAREPOINT CONTENT DATABASE
If you ever had the problem where you need to extract files from a SharePoint Content Database or no ...
- This content database has a schema version which is not supported in this farm.
I want to move the website to another server. The new server has reinstall Sharepoint2013 serv ...
- 如何从SharePoint Content DB中查询List数据
SharePoint用来维护基础数据非常方便,只需要建立自定义列表,然后使用InfoPath自定义一下维护界面,就可以实现在线的增删改查,开发效率很高.如果维护的数据需要进行审批,还可以加入工作流功能 ...
- SharePoint Config database Log file too big – reduce it!
SharePoint Config database logs are one thing to keep an eye on since they do have a tendency to gro ...
- Android Content Provider简介
Content Provider是Android的四大组件之一,与Activity和Service相同,使用之前需要注册: Android系统中存在大量的应用,当不同的应用程序之间需要共享数据时,可以 ...
- sharepoint content type publishing
1. Create 1 Project Team sites (Site1) on SharePoint(可以用普通site)2. Go to http://<PCName>:8080/_ ...
- DEDECMS5.5怎样调用{dede:field.content/}做简介之类的单独页面?
很多时候,如果用dede来做一些企业公司网站,或者一些部门网站的时候.需要某些栏目是一个单页的文章,用于公司简介或者企业文化之类的.那么就要用到栏目功能的栏目内容,也就是dede的content标签. ...
- SharePoint 2010 安装简介及相关补丁下载
转:http://www.cnblogs.com/jianyus/archive/2011/10/28/2228212.html 1.安装Windows Server 2008 系统,这个我就不说了, ...
- [SharePoint] SharePoint 错误集 2
1 Run command “New-SPConfigurationDatabase" Feature Description: error message popup after run ...
随机推荐
- 背水一战 Windows 10 (6) - 控件 UI: 字体的自动继承的特性, Style, ControlTemplate
[源码下载] 背水一战 Windows 10 (6) - 控件 UI: 字体的自动继承的特性, Style, ControlTemplate 作者:webabcd 介绍背水一战 Windows 10 ...
- RecyclerView和PullToRefreshListView的对比
项目中上拉刷新和下拉加载一直都是比较常见的:以前一般都是重写ListView或直接用PullToRefreshListView的框架:最近尝试用RecyclerView来实现下拉加载上拉刷新也是不错的 ...
- TestNG官方文档中文版(1)-介绍
TestNG的官方文档请见: http://testng.org/doc/documentation-main.html 1. 介绍 TestNG是一个设计用来简化广泛的测试需求的测试框架,从单 ...
- Spring Mvc 的自定义拦截器
spring mvc的拦截器 SpringMVC 中的Interceptor 拦截器也是相当重要和相当有用的,它的主要作用是拦截用户的请求并进行相应的处理.比如通过它来进行权限验证,或者是来判断用户 ...
- 原博客地址http://blog.chinaunix.net/uid/20656672.html弃用
原博客地址http://blog.chinaunix.net/uid/20656672.html弃用
- servlet同一用户不同页面共享数据
如何实现不同页面之间的数据传递,实现页面的数据共享?常见的方法有以下4种: 1)表单提交(form) 2)sendRedirect()跳转 3)session技术 4)Cookie技术 表单提交 这是 ...
- LBS数据分析:使用地图展示统计数据——麻点图与麻数图
作为一个LBS的APP,都获得了用户经纬度,也都使用了友盟统计.google ana等等统计分析系统,不过没有地图展示功能,不能进行直观的展示. 友盟统计.google ana等系统是总体数据统计,无 ...
- Javascript 语言精粹 代码片段合集
Javascript 语言精粹 代码片段合集 标签:Douglas-Crockford Javascript 最佳实践 原文链接 更好的阅读体验 使用一个method 方法定义新方法 Function ...
- sublime text 之添加插件 并使用
通过package controll install 安装各种插件: 1:AdvancedNewFile,安装完毕后 快捷键:ctr+alt+n:输入框中输入你要创建的文件夹和文件,就创建好了. ...
- JavaScript学习笔记-实例详解-类(二)
实例详解-类(二) //===给Object.prototype添加只读\不可枚举\不可配置的属性objectId(function(){ Object.defineProperty(Object ...