Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
How to increase the performance of jgGrid to populate more than 1000 rows
03/12/2010
13:52
Avatar
dm
Member
Members
Forum Posts: 4
Member Since:
02/12/2010
sp_UserOfflineSmall Offline

I have more than 1000 rows to populate data through jqGrid. When I populate data through jqGrid, jqGrid takes more than 20 seconds to populate data. This time is taken only by jqGird (query execution time and other time is excluded). I have a requirement to populate 1000 rows by using jqGrid and I don't want to use Pagination. Please help me how to increase the performance of jgGrid.

03/12/2010
14:10
Avatar
OlegK
Germany
Member
Members
Forum Posts: 1255
Member Since:
10/08/2009
sp_UserOfflineSmall Offline

I suppose that without the code example of your JavaScript code, full HTML code with the list of all JavaScript files which you load, information about versions which you use (versions of jqGrid, jQuery, jQuery UI and so on) and the test data (in JSON or XML format) nobody are able to help you. Only after having this information one can give you some tips for the performance improvement.

Moreover I am sure that your real requirement is a little other. No person can really able to read 1000 rows of the multi-column contain at ones. No monitor can show the 1000 rows at once, so the scrolling of data will be done either by the web browser or by jqGrid itself. So the usage of at least client side data paging can be used without changing of your requirements. Moreover the usage of client side data filtering for example with respact of Toolbar Searching or/and Advanced Searching could be really helpful for the users who will have to examine 1000 rows of data.

Best regards
Oleg 

06/12/2010
07:23
Avatar
dm
Member
Members
Forum Posts: 4
Member Since:
02/12/2010
sp_UserOfflineSmall Offline

Hi Oleg,

We are using jqGrid 3.6.4 and jquery 1.4.2 version. We are also using JSON datatype for displaying data in jqGrid. Following is the code snippet:

jQuery("#displayItemPerformanceGrid").jqGrid({
  url:'/DISMGMT/StandardProxy/displayItemPerformanceService?userRole='+userRole+'&userName='+userName+'&duration='+displayDuration+'&userId='+userId,
   datatype: 'json',
  colNames: ["CM", "Display Location", "Display Name", "Item", "Item Description", "Store", "DC", "Date", "Type", "Promo Retail", "Reg. Retail 50", "Units", "Sales $", "Profit $"],
  colModel: [{
    name: "cmName",
    index: "cmName",
    classes: "metric",
    width: 130,
    resizable: true,
    align: "left"
   },
   {
    name: "displayLocation",
    index: "displayLocation",
    width: 80,
    align: "left"
   },
   ...
   ...
   ...
   }],
  width: 982,
  height: 137,
  toolbar: [true, "top"],
  viewrecords: true,
  rowNum: 1500,
  gridview:true,
  loadonce:true
 });

In the preceding code snippet, when the URL goes to the server and get more then 1000 rows. Our business logic convert these 1000 rows in JSON format. Once all processes have been completed (retrive data from database and convert these data in JSON format), the control is transferred to jqGrid to pupoulate 1000 rows (in JSON format) in HTML page. Following is the code snippet of HTML page:
      <div id="displayItemPerformanceDiv" style="padding:0;margin:0;width:980px;height:200px;display: none;">
       <table id="displayItemPerformanceGrid" ></table>
      </div>

After the control is transferred to jqGrid to pouplate 1000 rows in HTML page, the jqGrid takes more than 20 seconds to populate data. Please, suggest me what can I do to increase the performance of jqGrid regarding for data population.

Note: Scrolling of data is maintained by jqGrid.

Thanks,
DM

06/12/2010
13:53
Avatar
OlegK
Germany
Member
Members
Forum Posts: 1255
Member Since:
10/08/2009
sp_UserOfflineSmall Offline

Sorry dm,

but the information which you posted is not sufficient to make any tests. I am enable reproduce your problem based on the information. You should prepare full example and not post only the definition of one column, some of jqGrid parameters and no test data. Till now I don't know which version of jQuery UI you use. Moreover I recommend you to use more recent version of the jQuery which has some performance enhancements. Till now you don't wrote also in which web browser (and which version) you made your tests.

To show you which can be performance of jqGrid with 1000 rows you can look at the following two example: one without paging and another used local paging. Is performance of this grids better as with your grid? I recommend you look also in the following post.

Best regards
Oleg 

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
55 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information