<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
	<title>jQuery Grid Plugin - jqGrid - Topic: Row Counts / Paging</title>
	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging</link>
	<description><![CDATA[Grid plugin]]></description>
	<generator>Simple:Press Version 5.7.5.3</generator>
	<atom:link href="http://www.trirand.com/blog/?page_id=393/help/row-counts-paging/rss" rel="self" type="application/rss+xml" />
        <item>
        	<title>tony on Row Counts / Paging</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7618</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7618</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>I like the simples solutions too 🙂</p>
<p>Regards</p>
<p>Tony</p>
]]></description>
        	        	<pubDate>Thu, 02 Jul 2009 05:19:14 +0300</pubDate>
        </item>
        <item>
        	<title>tomcmok on Row Counts / Paging</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7615</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7615</guid>
        	        	<description><![CDATA[<p>Tony,</p>
<p>If there&#39;s a request for 10 rows I&#39;m trying to fetch 11 (one more) by iterating throught the resultset (I have to do that anyway to build the XML/JSON). If there is at least one more row - it means there are more data and at this point it doesnt matter how many - this information is just required to let the paging display the "Next" icon</p>
<p>I&#39;m not sure how that solution would work in PHP, but I have my backend app server done in Delphi and there is a component that let&#39;s me iterate through the resultset and it informs me if there are no more rows to fetch.</p>
<p>I suppose that in PHP if you ask for 11 rows and load the resultset into an array, you can heck the real array length afterwards.</p>
<p>Smart and simple - isn&#39;t it 😉</p>
<p>The whole point is to keep in mind that the less SQL statements and the less fetches the better. Especially if you work on the databases with hundreds of tables containing hundred thousands of records or even more.</p>
<p>Cheers,</p>
<p>Tom</p>
]]></description>
        	        	<pubDate>Thu, 02 Jul 2009 04:53:31 +0300</pubDate>
        </item>
        <item>
        	<title>tony on Row Counts / Paging</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7599</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7599</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>Just for information - how do you check that there are more records - do you use SQL command for this purpose?</p>
<p>Regards</p>
<p>Tony</p>
]]></description>
        	        	<pubDate>Thu, 02 Jul 2009 02:55:40 +0300</pubDate>
        </item>
        <item>
        	<title>tomcmok on Row Counts / Paging</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7557</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7557</guid>
        	        	<description><![CDATA[<p>Well, instead returning the big total number of pages (what is the relativr big number? that depends on the databese you deal with). My solution is to check if there are more records and if so just return the information that there is ONE more page. this way the paging and page input work well</p>
]]></description>
        	        	<pubDate>Tue, 30 Jun 2009 11:37:53 +0300</pubDate>
        </item>
        <item>
        	<title>tony on Row Counts / Paging</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7515</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7515</guid>
        	        	<description><![CDATA[<p>Hello,</p>
<p>How should know the grid that there are more records for the next page, supposing that these records are in the database?</p>
<p>So the simple solution is:</p>
<p>Disable the record view, page input and total pages view, then server side return a relative big number for total pages without to query the database for such information.</p>
<p>Regards</p>
<p>Tony</p>
]]></description>
        	        	<pubDate>Sat, 27 Jun 2009 12:10:21 +0300</pubDate>
        </item>
        <item>
        	<title>tomcmok on Row Counts / Paging</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7476</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7476</guid>
        	        	<description><![CDATA[<p>What if you have complex SQL statement that joins several tables which itself takes time and a result gives you 100 thousands records. You will have to fetch them all just to count them and it will take quite some time and you will end up with displaying just ten. The difference in time may be couple of seconds wasted just to load into an array (not speaking about the unnecessary memory consumption).</p>
<p>T.</p>
]]></description>
        	        	<pubDate>Fri, 26 Jun 2009 10:03:38 +0300</pubDate>
        </item>
        <item>
        	<title>jkarlen on Row Counts / Paging</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7474</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7474</guid>
        	        	<description><![CDATA[<p>I ended up doing what I hinted at above.&#160; I do my query as normal, load it into an array and only return the portion of the array requested by the rows per page from the jqGrid request.</p>
<p>So far it loads incredibly quickly and still gives me access to the full record count.</p>
]]></description>
        	        	<pubDate>Fri, 26 Jun 2009 08:00:38 +0300</pubDate>
        </item>
        <item>
        	<title>tomcmok on Row Counts / Paging</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7471</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7471</guid>
        	        	<description><![CDATA[<p>hi, see my similar topic <a href="/blog/?page_id=18/help/can-i-avoid-counting-records/page-1" target="_self" target="_blank">here</a> I was hoping to get some hints from the author. Obviously counting records just to get the paging to work is not efficient - I&#39;ve suggested a sort of workaround that could solve the problem, without changing the js grid code</p>
<p>cheers, Tom</p>
]]></description>
        	        	<pubDate>Fri, 26 Jun 2009 03:05:26 +0300</pubDate>
        </item>
        <item>
        	<title>jkarlen on Row Counts / Paging</title>
        	<link>http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7467</link>
        	<category>Help</category>
        	<guid isPermaLink="true">http://www.trirand.com/blog/?page_id=393/help/row-counts-paging#p7467</guid>
        	        	<description><![CDATA[<p>What is the best way to handle row counts in conjunction with paging?&#160; If the SQL statement that generates the data has a limit statement on it then your number of rows will always be the limit or less.</p>
<p>It seems painful to run the query once, probably with just a count(*), just to get the whole universe and then run it again with the limit.</p>
<p>Would it be more efficient to run the query and filter $num_rows into a seperate array?</p>
]]></description>
        	        	<pubDate>Thu, 25 Jun 2009 18:05:47 +0300</pubDate>
        </item>
</channel>
</rss>