Total Count of Items in a List in Sharepoint
I had a recent assignment to test the performance of a List. The list was behaving really slow and I need to determine the total number of items in the list.
Aaaah ………… there starts the problem. I wanted the total number of items in the list and I could only do that by navigating through the List Item pages which was around 20,000 + Items, So need to click through every single pages and it would take couple of months to figure out the exact numbers. Then I thought about the "Calculated Columns" in Sharepoint.
Finally I figured out to get the total count of the Items in a Sharepoint List. Here are the steps -
Step 1.Create a "Calculated (calculation based on other columns) " column in the List
Step 2.Column Name - "Total"
The Type of Information in this column - "Calculated"
In the Formula Column put - "=SUM(ID)" (without apostrophise)
Select "The data type returned from this formula is: " as Number
Step 3.Select "OK" - a new column will be added to the List and then you could see the Column "Total" which would display values from 1 to End number in ascending order. If you click the header "Total" the list would be displayed in descending order displaying the Total number of the Items in the list.
Now.... however this is not an optimal solution considering that if you delete an item sharepoint still retains the ID and hence it still shows the total count (including the deleted item). So you can use this solution with a variation and use it appropriately.
To fix the total count issue, there is another solution; You can follow the below steps:
Go to the list, click on the list tab, Click on "Modify View"
Scroll to the bottom of the page, there will be an option called "Totals"
Click on the column which you want to show the count, select count option here it is the "Name column"
Now if you go back to the list, you can see a new column "Count" with the total count of items on it.
Hope this helps....... Do let me know your feedback .
Also If you are looking to filter a list based on user/Group permission, this post says it http://sharepointlogics.com/2014/02/how-to-filter-sharepoint-list-based-on.html