| Index
» Projekty
» phpMyEdit
» Fórum
» calculations |
 |
PLOS
Založený: 27.09.2003
Príspevky: 3
Zaslal: 2003-09-27 22:40
Návrat hore
Odpovedať s citátom
|
How do I calculate the sum of two fields and insert the answer in other field
Amount_1 (10.00) + Amount_2 (20.00) = Amount_3 (30.00)
Field 1 =Amount_1
Field 2 =Amount_2
Field 3 =Amount_3
Thank you
|
michal
Založený: 17.06.2003
Príspevky: 537
Bydlisko: Slovakia
Zaslal: 2003-10-03 01:18
Návrat hore
Odpovedať s citátom
|
there are two ways to do this:
sql option with a sql function to calculate this (if it exists, i don't know)
download patched version which includes possibility to define your own output function. then define this output function for your field. it is under bugs, named as output control.
|
PLOS
Založený: 27.09.2003
Príspevky: 3
Zaslal: 2003-10-03 02:22
Návrat hore
Odpovedať s citátom
|
Is there an example I can take a look at never used mysql I'm new to this
|
michal
Založený: 17.06.2003
Príspevky: 537
Bydlisko: Slovakia
Zaslal: 2003-10-05 16:41
Návrat hore
Odpovedať s citátom
|
me too, but have
$opts['fdd']['field3']['sql'] = 'field2 + field1';
where fieldi is name of the column in database
if field3 is not in the database, then some option with no A should be included.
|
PLOS
Založený: 27.09.2003
Príspevky: 3
Zaslal: 2003-10-05 17:35
Návrat hore
Odpovedať s citátom
|
Thank you, I downloaded the patch all is working fine;
|
spuri
Založený: 29.09.2004
Príspevky: 4
Zaslal: 2004-10-04 12:25
Návrat hore
Odpovedať s citátom
|
what kind if patch did you download?
|
michal
Založený: 17.06.2003
Príspevky: 537
Bydlisko: Slovakia
Zaslal: 2004-10-04 15:23
Návrat hore
Odpovedať s citátom
|
see bug #127
|
|
Odoslať novú tému
Odpovedať na tému
|
|
|
|