简体   繁体   English

在SQL中访问共享点列表数据

[英]Access sharepoint list data in SQL

I am new to SharePoint development. 我是SharePoint开发的新手。 I have a list, this list has a column that is called Todaysdate . 我有一个列表,此列表中有一列称为Todaysdate This column needs to be updated daily to today's actual date and since it contains ~20,000 rows I am NOT going to update it manually everyday. 该列需要每天更新为今天的实际日期,由于它包含约20,000行,因此我不会每天手动进行更新。 Because it's used in a calculation row. 因为它在计算行中使用。

My question is can I just use SQL and update the rows in the UserData table that correspond to the datetime column that I need? 我的问题是我可以只使用SQL并更新UserData表中与我需要的datetime列相对应的行吗?

I can query the list of rows by something similar to 我可以通过类似的方式查询行列表

Select * from UserData where tp_ListID = 'GUID'

but the data contained in the column datetime3 is not just the Todaysdate information. 但是datetime3列中包含的数据不仅是Todaysdate信息。 How do I return just the Todaysdate info? 我如何只返回Todaysdate信息?

You really should not query let alone update the SharePoint content database directly using SQL. 您确实不应查询,更不用说直接使用SQL更新SharePoint内容数据库了。 It is totally unsupported, so if you break something you are left alone, and the database schema may change with future service packs / releases. 它是完全不受支持的,因此,如果您破坏某些内容,您将独自一人,并且数据库架构可能会随将来的Service Pack /发行版而更改。
Also as noesgard mentioned it in his comment you do not need it to use today's date in a calculated field, see this blog entry on how you can do that. 同样,正如noesgard在其评论中提到的那样,您不需要它在计算字段中使用今天的日期,有关如何操作的信息,请参阅此博客条目

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM