Welcome Guest, Not a member yet? Register   Sign In
[SOLVED] Need example of set_join_fields to update multiple rows
#2

[eluser]WanWizard[/eluser]
Code:
// mark this alarm as fired
$alarm->set_join_field($user, 'wasfired', TRUE);

// mark all alarms related to users as fired
$alarm->set_join_field('user', 'wasfired', TRUE);

You only need the "relationship key" instead of the model name if you have the defined the relationship as advanced, and used a custom name for the relation.

If this doesn't work, what is the result of $alarm->check_last_query()?


Messages In This Thread
[SOLVED] Need example of set_join_fields to update multiple rows - by El Forum - 06-01-2011, 02:34 AM



Theme © iAndrew 2016 - Forum software by © MyBB