Index
» Projekty
» phpMyEdit
» Fórum
» HELP PLEASE! HOW TO STORE A VIRTUAL VALUE |
|
pj
Založený: 02.07.2014
Príspevky: 2
Zaslal: 2015-07-22 14:20
Návrat hore
Odpovedať s citátom
|
Hi there!
Since last days Im stuck on this problem.
I'm virtually generating a value. I can see it on the table, but I need to store it on the database. I have tried lots of possibilities and nothing helps me.
Any suggestion will be highly appreciated
The code:
$main_table2 = 'p_management_project_members';
$join_table2 = '(SELECT project_manager, SUM(bonus_percentage) as total2 FROM p_management_bonuses GROUP BY project_manager)';
$opts['fdd']['bonus_percentage'] = array(
'name' => 'Bonus (%)',
'select' => 'T',
'values' => array( // API for currently making a join in PME.
'table' => $join_table2, // the table to which we're joining
'column' => 'project_manager', // the key field in the joined table
'join' => '$main_table.member = $join_table.project_manager',
'description' => 'total2'
// the desired column in the joined table
),
'options' => 'RLF',
'maxlen' => 65535,
'textarea' => array(
'rows' => 1,
'cols' => 5),
'sort' => true
);
|
doug
Založený: 10.02.2003
Príspevky: 1013
Bydlisko: Denver, Colorado (USA)
Zaslal: 2015-07-23 15:50
Návrat hore
Odpovedať s citátom
|
http://opensource.platon.org/projects/doc.php/phpMyEdit/html/configuration.triggers.html
Three triggers might be the answer, insert, update, delete. Use the forum Search features to locate trigger examples.
|
Odoslať novú tému
Odpovedať na tému
|
|
|
|