New answers tagged splist
There is an XML type in PowerShell. Exploring XML Document by Using the [XML] Type Accelerator Define $a as [XML]$a = $item["XMLField"]; Now you would be able to lookup set the value of NodeImLookingFor as $a.NodeImLookingFor = "New Value"; Regards
We can get the Checked out files using the below code. No matter what you try, you cannot get the checked out files by querying the document library as these are saved in a separate table in the database. SPDocumentLibrary library = (SPDocumentLibrary)list; IList<SPCheckedOutFile> files = library.CheckedOutFiles; foreach (SPCheckedOutFile file in ...
Using CAML query is the best option for retrieving data. As list grows if the result set has more than 5000 items, then performance will degrade. To handle this situation as SCMC suggested you should add indexes to fields used in the WHERE clause. If you still observe performance issues, the I would suggest using Pagination. So get items in set to X items. ...
Make sure that the column you include in the where clause is defined as an indexed column in SharePoint. You can check by going to the list you're querying and into List -> Settings -> Indexed Columns. It's not applicable in your CAML query, but if you have more than one 'where', ensuring the first where hits an indexed column can increase efficiency. ...
I think fallout's answer partially answers the question. His 'if statement' checks if items exist, then updates items if they exist, otherwise it creates new items if they do not exist. Depending on your columns, the trick is to update only those items that have changed in the CSV file (required for efficient version control in the sharepoint list).
Top 50 recent answers are included