5000 Threshold, CSOM, Javascript Object Model SharePoint, SharePoint 2013, SharePoint List Lookup, Sharepoint2010, Uncategorized

Get 50000 items from SharePoint List using JS-SharePoint Item 5000 Threshold Issue [Solved] –


My blog will help to load data from SharePoint list regardless of list-view threshold limit . I have been through many forums and even I experienced bit difficulty to load data from list having record greater than limit defined by the SharePoint administrator (threshold limit). I have created a simple JS file with some functions to load data in chunks. i.e. My JS function will automatically take the total count of list and break them in the chunks and iterate them. In the result it will provide the array of items requested by the user.

Global Varaiable

Screen shot is to provide the global variable for our JS File

Initial Method to Call from my js

Initial Method to Call from my js

Internal method of JS File, This methods will take the cound of the List and divide them as 5000 each cycle

Internal method of JS File, This methods will take the cound of the List and divide them as 5000 each cycle

 

 

 

Final Methods will runs once all the data finish loading

Final Methods will runs once all the data finish loading

Just add the attached JS file to your SharePoint Solution and call the below mentioned function. In return once the data get loaded , it will write the desired array to flatArray and update var TransactionComplete = 1; further you can use flatArray with data in your app.
JS File – Click here to Download – Rename PDF to JS

Funciton to call GetListItem(siteurl,listname,columns)

siteurl = http://sitename

listname=testlist

columns=ID,Created,Title,Column1,Column2,Column4,Column5

Result = flatArray as Array

Resultant Screen shot.

ResultArray

ResultArray

 

I hope my little efforts may save time for those who are struggling with SharePoint threshold 5000 issue.

Standard
Info Path 2013, Sequential WorkFlow Visual Studio 2010, SharePoint 2013, SharePoint List Lookup, Sharepoint2010, Visual Studio 2013

InfoPath and SharePoint 2013, Deploy Browser Enable form in SharePoint 2013, Info Path 2013 and SharePoint 2013


I got a chance to migrate our solution to SharePoint 2013. After our analysis and the research my first target is to deploy the Info Path Browser enable form to SharePoint 2013. Here I am sharing my experience to deploy info path 2013 forms to SharePoint 2013 Portal.

In SharePoint 2013 we have 15 hive or root folder earlier we had 14 hives in SharePoint 2010. For Learning the SharePoint 2013 road map uses the link below.

http://technet.microsoft.com/en-us/library/jj937861.aspx .

When Deploying my Info Path Forms which I built on Info Path 2010 , I didn’t find to much difficulties but some new thing I have encounter. Likewise  Previous Info Path 2010 Visual studio tool based on the .net framework 2.0, now it is based on the 4.0 and also the SharePoint 2013 is also based on .net framework 4.0 (Resource : http://weblogs.asp.net/soever/archive/2012/07/20/sharepoint-2013-is-running-on-net-4-framework.aspx and the Screen shot of our farm).

App Pool shows the Framework of SharePoint 2013

App Pool shows the Framework of SharePoint 2013

(1) To deploy our 2010 info path form we just need to open the Visual studio code editor, and change the frame work to 4.0.

Target Framework should be 4.0.

Target Framework should be 4.0.

2) We need to change the Reference to SharePoint Dll, if there is any server side object model is used, in the SharePoint 2013, its location is in 15 hive ISAPI Folder.

15 hive folder for reference Microsoft.SharePoint, for any crud in the List

15 hive folder for reference Microsoft.SharePoint, for any crud in the List

We also need to remove the already reference System.Addin.Contract cuz form the below diagram, It is already referenced.

System.Addin Contract

System.Addin Contract

Just deploy as Administrator Approved form like we usually do in SharePoint 2010 and rocks.

Standard
SharePoint List Lookup

Provisioning LookUp Field in SharePoint 2010, LookUp Field in the List In SharePoint 2010


A simple way to create a look field relation with the SharePoint List. In this blog I will create a one site column of type lookup, and add to the newly created content type. Helpful links for lookup fields in SharePoint 2010 are Provisioning Lookup Fields, lookup fields by msdn .I have document here in my blog so that I will have clear picture of lookup fields. In this blog I am going to add a look up field to a list trough visual studio 2010, simple step by step with the simple project.

First We Create a List Instance in the Visual Studio2010.

We will Add our Created Lookup Field to this List .

Simple List Instance

Simple List Instance (Movie)

As Lookup Fields obtain their values from an existing list. Each Lookup Field is being linked to its list using the list’s ID. As the ID’s are being generated after creating the instances there is no way to provision a Lookup Field linked to a newly created list during Solution deployment.
(1) Create Empty SharePoint Project

CreatingEmptySpProject

CreatingEmptySpProject

(2) Deployed it as Sandbox Solution

DeploytAsSandbox_2

DeploytAsSandbox_2

(3) Adding List Instance to the Project. This List column will be use as a lookup column in the main list.
List Name is GenreLooupField.

GenreLookUpListInstance_3

GenreLookUpListInstance_3

(4) Adding Default Rows to the List

AddingDefault_Rows

AddingDefault_Rows

(5) We will add a Site column definition by adding a new empty element in the project.

ColumnDefinition_6

ColumnDefinition_6 empty element

(6) Add the definition for the site column.

SiteColumnDefinition

SiteColumnDefinition

Type of this column is LookUp
At this stage site column with the list definition has created. Next is to create the content type in which above site column will be mentioned. Last step will add this content type to our movie list.
(7)Add new item (Content type) in the project

contenty_type

contenty_type

Choose the Announcement to this content type inherit form, then open the element.xml below the content type and add the the reference of the site column through ID.

contentype site definition reference

contentype site definition reference

Deploy the Project.

Go to the List Setting then Advance Setting ,Allow management of content types. Add the content type which we created above. then click below on list setting-> Add from existing site content types

add existingsite contentytype

add existingsite contentytype

.
Make added content type as default content type of list (movie).

associate contenty type to list movie

associate contenty type to list movie

,
Look up field added to the list.

ListwithLookupFields

ListwithLookupFields

Download Project

Standard