This topic is locked

After Record Added/Update no longer work in V5.3

2/8/2011 8:16:33 AM
PHPRunner General questions
J
Jattie author

I have a week column in a timesheet application that I updated from the date returned by the submission and then updating the same table field with a week number:
So from one of the field submitted I calculated a week number:

$DateWeekNum=date("W",strtotime($values["Date"]));


and then inserted that number in the same table using the code below:

global $conn;

$strSQLInsert = "update timesheet set week=".$DateWeekNum." where idx=".$values["idx"];

db_exec($strSQLInsert,$conn);
exit();


The problem in version 5.3 is now that the index ("idx") value is not populated and shows a null value.
Is this by design or am I missing something else?

Sergey Kornilov admin 2/8/2011

If idx is a key column you need to access it as $keys["idx"].
More info: http://xlinesoft.com/phprunner/docs/after_record_added.htm