This topic is locked

need to modify the where

12/6/2007 7:07:34 AM
PHPRunner General questions
M
mounir author

hello all ,

i need to modify the where in the sql request for aview page ,

so here is my problem :

i have a list page , in the sql request : i have a test only on a field ( the foreign key ) but i want to add a test for another field

in phprunner 4.1 i see the event " BeforeQueryView" i try to use it but there result is not chaged here is my code !!
[codebox]// View page: Before SQL query

function BeforeQueryView(&$strSQL,&$strWhereClause)

{

//** Custom code ****

// put your custom code here
//echo "### strSql =$strSQL and strWhereClause = $strWhereClause" ;
$strWhereClause+=" and param_id=$last_param_id";
} // function BeforeQueryView[/codebox]
as showen in the code the param i want to add in where clause is param_id
thanks for help and / or suggestions

Alexey admin 12/6/2007

Hi,
at first you need to use .= operator instead of += here.
Also it's not clear where $last_param_id parameter comes from.

I recommend you to contact support team directly at support@xlinesoft.com

M
mounir author 12/6/2007

Hi,

at first you need to use .= operator instead of += here.
Also it's not clear where $last_param_id parameter comes from.

I recommend you to contact support team directly at support@xlinesoft.com



thanks for your reply

even when i try this new code it doesn't work , it is like if we dont execute that event !!

Alexey admin 12/6/2007

You can publish your project on Demo Account (last tab in PHPRunner) and send a URL where I can see this problem to support@xlinesoft.com

I'll help you to get this working.

M
mounir author 12/6/2007

You can publish your project on Demo Account (last tab in PHPRunner) and send a URL where I can see this problem to support@xlinesoft.com

I'll help you to get this working.



if u want we can do a net meeting or sth but i cant publish the project

M
mounir author 12/7/2007



if u want we can do a net meeting or sth but i cant publish the project



ok i see , i will send u the link once the demo account done

thank you