Q:

Display grand total in the footer so that value remains same on page change for load once true

I am implementing JQGrid and sending the datatype as JSON. Also, I've set loadonce as  true, and I am able to get the footer summary correctly in the footer.
However, on page navigation, the total value changes according to the row data in each page. My requirement is to display the grand total of all the records of the particular column so that the footer value remains same on page change.
I am using the following code to get the footer summary:
var grid=$("#mygrid");
sum = grid.jqGrid('getCol','amount',false,'sum');
grid.jqGrid('footerData','set',{ID:'Total:',amount:sum});

A:

You can use userDataOnFooter option to achieve your goal. First you set this option to true while initializing:
$("#mygrid").jqGrid({
    ...
    footerrow : true,
    userDataOnFooter : true,
});

After that you can send the values for footer row in your response, JSON should look something like this:
{
    total: x,
    page: y,
    records: z,
    rows : [
        { id: "1", cell: ["value11", "value12", "value13"] },
        { id: "2", cell: ["value21", "value22", "value23"] },
        ...
    ],
    userdata: { ID: "Total:", amount: <sum counted on server side> }
}

There is also live example available on jqGrid Demos page, you should choose "New in Version 3.5" and then "Summary Footer Row".

