CodeCharge Studio
search Register Login  

Visual Web Reporting

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

YesSoftware Forums -> CodeCharge Studio -> PHP

 Set GROUP BY in report based on Search parameter

Print topic Send  topic

Author Message
knoops


Posts: 23
Posted: 08/10/2007, 9:28 AM

I am sure somebody has wanted to do something like this before.

I have a database with an accesslog. I want a small searchform, which enables the user to pass the GROUP BY-parameter to the report. (Either user or logmessage). Strangely enough Codecharge Studio does not allow me to get URL-parameters as part of the GROUP BY-query, like with the WHERE statement. It only allows an expression. (Actually, when I bought the extended license, I expected the Searchbuilder in the Reportbuilder to automatically generate a selectionlist for GROUP BY like it does with ORDER BY... I'll add it to the wishlist)

So I figure the solution is to see if Custom Code in the BeforeShow of the Report would be able to read the URL parameter and set is as the GroupBy-property of the report somehow. But I try to avoid Custom Code as much as possible and it seems like a common task in creating usable reports.

Am I overlooking something here of is the idea of using the classes in Custom Code a good solution?

Thanks for any thoughts on this matter.

Knoops
View profile  Send private message
Benjamin Krajmalnik
Posted: 08/12/2007, 2:02 PM

Not before show - that is too late.
You should use BeforeBuildSelect to dynamically set your group by value.

Wkempees
Posted: 08/12/2007, 2:51 PM

@B,
Dynamically adding the Group By
by changing/adding it to the Where
??

Walter
knoops


Posts: 23
Posted: 08/13/2007, 1:44 AM

Off course... BeforeBuildSelect.
I will try to add the GROUPBY to the WHERE-clause of the SQL. It will be dirty coding, that's obvious. If anybody can think of a cleaner/more generic solution...
View profile  Send private message

Add new topic Subscribe to topic   


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

MS Access to Web

Convert MS Access to Web.
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.