List View Threshold - sharepoint

I have a Sharepoint List that exceeded 5000 items limit today. After reading numerous suggestions, I:
indexed columns
Created a filtered default view that returns 3000 items.
Even though the default view now returns only 3000 items. In the List Settings Page I still see an error message saying "The number of items in this list exceeds the list view threshold, which is 5000 items. Tasks that cause excessive server load are currently prohibited. Could you please let me know what could be an issue and why filtering and indexing didn't help? Thank you!

Please do the following troubleshooting:
1.Columns with column types like people, lookup, or managed metadata can cause list view threshold errors when sorting. Therefore, we recommend that you can use text, number, date, and other column types in the first sort.
2.Displaying 12 or more columns of the following types can cause a list view threshold error: people, lookup, and managed metadata. Displaying columns of other types will not.
3.Clear the browser cache or test with another browser.

Related

Sharepoint 2013/2016 Calculated Column stops calculating

I have a calculated column in SharePoint On-Premises that shows the number of days till a due date which works perfectly for a day or so then stops calculating, but if I go to the list settings and click the column and click ok then it calculates again?
Has anyone experienced an issue similar to this. I had this issue in both 2013 but within a few weeks moved to 2016 and still the same issue.
I've tried " " blank and also "" empty so not sure if that is causing the issue??
Is it a problem with the formula?
Here is the formula:
=IF(ISBLANK([Due Date])," ",
IF(ISERROR(DATEDIF(NOW(),[Due Date],"d"))," ",DATEDIF(NOW(),[Due Date],"d")))
Calculated columns cannot contain volatile functions, which includes those that depend on the current date.
The values in SharePoint columns--even in calculated columns--are stored in SharePoint's underlying SQL Server database.
The calculations in calculated columns are not performed upon page load; rather, they are recalculated only whenever an item is changed (in which case the formula is recalculated just for that specific item), or whenever the column formula is changed (in which case the formula is recalculated for all items).
If you need to show a dynamic value that changes with the passage of time, you have a few alternatives.
Client-Side Rendering
Consider using client-side rendering which lets you use JavaScript to dynamically determine how records in a list view are displayed. This JavaScript runs upon page load, so it can handle current time-dependent values much better than a calculated column.
To use client-side rendering, you create a JavaScript file that controls how the view displays. You upload that file to somewhere on SharePoint where people will have at least Read access to it, then edit the list view web part that you want to display differently and set its "JSLink" property to point to your JavaScript file.
Check out this answer for an example of using a JSLink file to spoof a dynamic date field.
Microsoft also provides some documentation here but I think they do more work than is necessary (creating an entire new list definition project in Visual Studio for their example instead of just creating a JSLink JavaScript file for an existing list).
Other Options
A few other options are mentioned in the older question linked above:
Conditional Formatting: You can apply conditional formatting to highlight records that meet certain criteria. This can be done using SharePoint Designer or HTML/JavaScript.
Filtered List views: Since views of lists are queried and generated in real time, you can use volatile values in list view filters. You can set up a list view web part that only shows items where Created is equal to [Today]. Since you can place multiple list view web parts on one page, you could have one section for today's items, and another web part for all the other items, giving you a visual separation.
A workflow, timer job, or scheduled task: You can use a repeating process to set the value of a normal (non-calculated) column on a daily basis. You need to be careful with this approach to ensure good performance; you wouldn't want it to query for and update every item in the list if the list has surpassed the list view threshold, for example.
To expand on the Filtered List Views option, you can have a view that shows only items that are due within a certain number of days. For example, you can display all the items due within 7 days by filtering where the Due Date field is less than [Today]+7 and Due Date is greater than or equal to [Today]. You could also sort the view to show the items with earlier due dates closer to the top.

IBM Cognos Report Studio: Inserting Data Items from same Dim on Report Page

I have tried to insert two data items to the report page, in which one is an element from a dimension (lets say CurrentItem), and the other one is just
parent(CurrentItem)
I have already done the same for elements from another dimension, which worked out fine after associating the page with the query. However, for these two elements I get the following error:
XQE-PLN-0213 The report nests levels from hierarchies 'DimName' breaking the hierarchy level order. Please nest levels according to natural hierarchy level order.
This page should have provided me with a solution: http://www.ibm.com/developerworks/data/library/cognos/upgrade_and_migration/bi/page568.html
However, as I already have done this with another dimension for the same query in the same report, it does not really make sense.
It might be worth adding that the following query expression is defining one of the rows in my query:
descendants([CurrentItem], 1)
But, removing this row does not make any change. The only way I get rid of the error is when I remove one of the data items that I have inserted directly on the page.
Anyone have any idea why this is happening / not possible?
Thanks!

Query problem with lookup column in SharePoint

Setup:
I have two lists on a SharePoint site, A and B. List A has a column 'b' that is a lookup to the ID field of list B. I have 500k+ records in A and about 6k records in B.
What works:
I am able to execute a query for items in list A using SharePoint web services, and am even able to filter the query based on a specific "lookup" value for column 'b'. For example, I can query for items in A whose column b matches 1234 (...<Value Type="Lookup">1234</Value>...), and so on.
What doesn't work:
The query does not work for items older than a specific date, even though my query does not involve dates in any way -- only the lookup column. Any query on data newer than two years old works fine, anything older than that fails. If I view items from the SharePoint web page they appear ok, and all the links from child records in B to parent records in A work just fine -- the lookup columns appear intact.
Question:
Is there some kind of maintenance task in SharePoint that can cause some underlying data to get corrupted that can prevent a query based on a lookup id to stop working, like a system restore, etc? In other words, the lookup column data appears correct on the surface in the web browser. But does SharePoint represent this value with a GUID or other invisible data that might be out of sync or stale?
Thanks.
Maybe you are hitting another limit; the maximum number of items retrieved in a query?
See list throttling
Try querying by the ID by adding the LookupId=”TRUE” attribute to your FieldRef element.
http://abstractspaces.wordpress.com/2008/05/05/caml-query-lookup-field-by-id-not-by-value/
The problem appears to be related to the fact that the column in question was indexed. When I removed the index everything started working. When I reapplied the index, everything kept on working. I'm attributing this problem to a corrupt index.

Append Query From Access Into Linked SharePoint List with Lookup Fields in SP List

I am trying to append records in an MS Access table (I am using Access 2010, but can use 2007 if need be) into a linked SharePoint list.
There is an attachments field (when viewed from Access), but I am not concerned with appending these.
The SharePoint list has a few lookup fields, that in design view are of the Number format. Upsizing to SQL Server, I can confirm that they are numbers (and I assume the Id for the related SharePoint list object).
I copied the structure of the SharePoint list and pasted into a MS Access table, and then filled in a few sample records
I used the query wizard to select all of the fields of the Access table (minus the Access table's autonumbered ID and attachments), click "Append", and then selected the SharePoint list.
If I run this query, I get the error that X record(s) were not appended due to validation violation reasons, which is all of them. I've checked all field definitions and none are defined as required or have a validation constraint.
The only thing I can think of is that there is some issue with the Lookup fields, but each number Id I've checked is a valid Id.
I'm hoping for a MS Access solution, but if the only approach is to programmatically do it, could someone send me directions on how to get started with the SharePoint 3.0 SDK?
Thank you for your time.
Lookup columns are not number type even your parent items are of number type reason behind lookup column always attaches the item id of parent item.If you want to see the data in access kindly use the "export to Access" functionality available in datasheet view
I have linked to a SharePoint table, then appended directly to it from a query.
My issue is that this process takes a very long time to push up to SharePoint, then 2 times as long when first I need to delete the records currently in the list before appending.
Is there a better way to blow out and create the table while preserving the link since it is not an Access object?
Anyway I hope this may help you out some and get me some insight as well.
Regards.

Retrieving a sharepoint list in Infopath only shows first 100 records

I am retrieving a list of values from a sharepoint list, which works well but my problem is that it only retrieves the first 100 records. there are currently 500 records that should be available.
Scenario: I have two comboboxes on an infopath form:
A List of Locations
A list of areas within the locations
the list of locations will filter the list of areas but as infopath seems to only retrieve the first 100 records so most of the locations do not show any areas as there is nothing to filter.
By design, the query will only return the first page of results from the default view for the list. Change the item limit for the default view in SharePoint, and you'll change the returned values for InfoPath.
EDIT (links from my comments, here for greater readability):
Here are sources describing this fix in MSDN forum (scroll to the bottom), a blog comment that describes the SharePoint setting step-by-step, one with a screen cap of the somewhat counter-intuitive interface, and another describing performance implications on the server side.
Hope this helps.
Just documenting what I have discovered trying to resolve the problem. I have not been able to change the default view as yet as I dont have the permission to. That should change though.
One possible workaround I have found is that you can export the list to Excel which contains all the data that I was looking for. the file that sharepoint produces is an Excel Query file like "export.iqy". You can save and open the file in notepad. which will look something like the following
WEB
1
http://SharepointSite/_vti_bin/owssvr.dll?XMLDATA=1&List={14C4ED2B-3050-4C47-B5F3-6333C3B0FB28}&View={8E6124E0-23F2-4BA2-86E7-96E7F36BAEC8}&RowLimit=0&RootFolder=%2fLists%2fSharepoint%20Sites
Selection={14C4ED2B-3050-4C47-B5F3-6333C3B0FB28}-{8E6124E0-23F2-4BA2-86E7-96E7F36BAEC8}
EditWebPage=
Formatting=None
PreFormattedTextToColumns=True
ConsecutiveDelimitersAsOne=True
SingleBlockTextImport=False
DisableDateRecognition=False
DisableRedirections=False
SharePointApplication=http://SharepointSite/_vti_bin
SharePointListView={8E6124E0-23F2-4BA2-86E7-96E7F36BAEC8}
SharePointListName={14C4ED2B-3050-4C47-B5F3-6333C3B0FB28}
RootFolder=/Lists/My list
You can take the third line which is -
http://SharepointSite/_vti_bin/owssvr.dll?XMLDATA=1&List={14C4ED2B-3050-4C47-B5F3-6333C3B0FB28}&View={8E6124E0-23F2-4BA2-86E7-96E7F36BAEC8}&RowLimit=0&RootFolder=%2fLists%2fSharepoint%20Sites
And use that to retrieve the complete list. I added an new receive data connection, selected an xml document and added the above URL.
It is not formated particullary nice but it will return all the data that I was expecting.
I think that Argalatyr solution is much simpler at this point, but it depends on if i am able to get the default view changed.
there is yet one workaround of this without such hardcoding. If you open Query editor, then you have there available ribbon with menu items. Open "Home" -> "Select top rows" and enter there some realy high number (I have in my list 596 rows, so I entered there as limit of top rows 20000 and I got whole list).
Sorry, I don't have available English version of Excel, so I cannot add screenshots.
enter image description here

Resources