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

 [CC] Parameters for custom SQL

Print topic Send  topic

Author Message
Claudio Navarro H.
Posted: 06/18/2003, 2:01 PM

Hi!

I'm actually using CC. i generated a page with two forms (a search and a grid), and on the grid i have a custom SQL sentence (a Join for four tables in T-SQL). I'm using aliases for the tables, and have a "where" condition.

In the Search form, i have four filter fields, which change the "where" condition for my custom SQL, but when i apply a filter, CC modify my custom SQL adding the field (and that's right), but not add the alias for my tables, and the field name is repeated between the tables...

How i tell to CC put alias in the fields?

an example of my custom SQL:

SELECT T1.CUSTOMER_ID, T1.NAME, T2.WORK_ID, T2.DESCRIPTION, T2.DATE
FROM TABLE1 T1 LEFT JOIN TABLE2 T2 ON T1.CUSTOMER_ID = T2.CUSTOMER_ID
WHERE T2.ORDER_STATUS = 'CLOSED'

and when the search is executed, CC add this :

SELECT T1.CUSTOMER_ID, T1.NAME, T2.WORK_ID, T2.DESCRIPTION, T2.DATE
FROM TABLE1 T1 LEFT JOIN TABLE2 T2 ON T1.CUSTOMER_ID = T2.CUSTOMER_ID
WHERE T2.ORDER_STATUS = 'CLOSED'
AND CUSTOMER_ID = '12345-6'
~~~~~~~~~~~~
without the alias

any suggestions?

Thanks, and sorry about my bad english...

Claudio.
Claudio Navarro H.
Posted: 06/19/2003, 9:08 AM

related to the last question, how i can modify the query string programatically?

thanks!

Claudio.

   


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

PHP Reports

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

Home   |    Search   |    Members   |    Register   |    Login


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