SharePoint 2007 中缺少 SharePoint Server 发布基础结构功能
我正在尝试在我的 Sharepoint 站点的页面上显示 sql 查询结果。环顾四周后,我找到了有关如何使用内容查询 Web 部件执行此操作的说明。启用该功能的说明此处的说明包括激活 SharePoint服务器发布基础设施。我目前没有这个选项。我可以在我的共享点网站上安装一些东西来获得该选项吗?有没有更好/更简单的方法来显示 sharepoint 中 sql 查询的结果?
I am trying to display a sql query result on a page in my Sharepoint site. After looking around I found instructions on how to do that using the Content Query Web part. The instructions to enable that feature instructions here include activating the SharePoint Server Publishing Infrastructure. I currently don't have that option. Is there something I can install to my sharepoint site to get that option? Is there a better/easier way to display the results of a sql query in sharepoint?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
请务必查看“网站集功能”而不是网站功能。此功能需要在网站集的根级别激活。
仅供参考,内容查询 Web 部件仅从您的网站集中检索内容(通过制作相关的 CAML 查询,最终转换为 SQL 查询)。您无法创建直接的 SQL 查询并接收结果。
如果您需要查询 SharePoint 正在使用的数据库之外的另一个数据库(不惜一切代价避免从 SQL 访问它!),您将需要依赖 Business Connectivity Service、数据视图 Web 部件(使用 SharePoint 设计器),或者创建一个简单的 Web 部件将负责一切(连接到数据库、执行查询并以任何方式呈现结果)。
希望有帮助。
Make sure to look in your "site collection features" instead of your site feature. This feature needs to be activated at the root level of the site collection.
FYI the Content Query WebPart only retrieve content from your site collection (by crafting a relevant CAML query, which is finally transformed to SQL query). You don't have the possibility to create a direct sql query and receive the result.
If you need to query another database than the one SharePoint is using (avoid accessing it from SQL at all cost !), you'll need to rely on the Business Connectivity Service, a data view webpart (using SharePoint designer), or create a simple webpart that will be responsible for everything (connecting to the db, doing the query and rendering the result in any way).
Hope it helped.