This topic is locked

where clause in Chart

9/12/2012 9:36:43 PM
PHPRunner General questions
W
wildwally author

Ok, need some help in understanding what the difference is and why both work yet the $_GET will not.
So I have a chart and I used this in the Before SQL Query to filter to the specfic project
$strWhereClause = whereAdd("QuoteFileName = 'XYZ'",$strWhereClause);
Digging through the forum i found found this works too
$strWhereClause = whereadd($strWhereClause, "QuoteFileName = XYZ");
However I'm trying to load the variable from the URL which I've done before all I get is the dial spinning saying no data.
$strWhereClause = whereadd($strWhereClause, "QuoteFileName = '".$_GET["quotename"]."'");
Now I've tried this both ways and same result. I see the variable is correct in the URL. So what gives and what's the difference for the first two and what is the proper way?

Sergey Kornilov admin 9/12/2012

In short - you need to use session variable instead of URL parameters. You pass URL parameters to the main chart page (i.e. My_Chart_chart.php) while data retrieved by dchartdata.php file which don't have access to this $_GET variables.
Here is the article that provides more info on relation between these two files:

http://xlinesoft.com/blog/2012/05/22/troubleshooting-charts-in-phprunner-and-asprunnerpro-applications/