CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> GotoCode Archive

 Navigator problem

Print topic Send  topic

Author Message
Jeroen Steggink
Posted: 06/21/2002, 1:59 AM

Hi,

Most of the time my navigator doesn't seem to work.
I limited the pages records to 15 and I have 48 records. But the navigator only shows the first page. So I only see the first 15 results and I can't go to another page using th navigator. Simply because it says 1 of 1 instead of 1 of 4.
What am I doing wrong?
Nicole
Posted: 06/24/2002, 2:17 AM

Hello,
Do you work with CC or CCS? Please check navigator settings in both cases.
Richard Brown
Posted: 10/30/2002, 6:36 AM

I get the same thing when I load the grid from a stored procedure, I'm using CCS, any ideas?
CCS Support
Posted: 10/31/2002, 6:55 AM

Richard,
Navigator may not work if custom sql includes GROUP BY clause. Let me provide some explanation how count sql is built. The approach is simple, the field listing in SQL is replaced with count(*) preserving the rest part. As you’re using custom sql, the Where and Group By clauses are preserved as well, because they are included into SQL variable (as you can see in generated code). So, after replace you get sql like:
Select count(*) FROM companies
WHERE
company_id = {CompID} AND
description LIKE '%{s_description}%'
GROUP BY item_id

If you run such query you’ll get the not one record in recordset but the same number of records as in normal query. But it is expected that countSQL returns one record only, thus only first one is retrieved. In your case the retrieved vale is 1, that’s why navigator doesn’t work.

To overcome the problem you should use custom query instead generated countSQL like:
Select count(*) from companies where company_id = {CompID} description LIKE '%{s_description}%'
Experiment with different queries against db and find one that works correct.

Overwrite countSQL in the form Before Execute Select
ystyves
Posted: 02/03/2003, 5:43 AM

just for the one that didn't figure out by themselves

it's not in the form Before Execute Select that you must overwrite datasource.CountSQL but in the form Before Build Select

it worked well for me

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

Web Database

Join thousands of Web developers who build Web applications with minimal coding.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.