This topic is locked

Fetching report totals for calculations

3/20/2017 2:56:57 PM
PHPRunner General questions
mbintex author

Hi at all,
tried to calculate with Report totals with something like this:
$links = $xt->getvar("groupKonto_totalBetraglinks_sum");

$rechts = $xt->getvar("groupKonto_totalBetragrechts_sum");

if ($links>$rechts)

$xt->assign("kontensaldo",$links-$rechts);

else

$xt->assign("kontensaldo",$rechts-$links);
Had to learn from Support, that with getvar I can´t fetch the Content of Report totals, since These aren´t unique in a Report.
Is there any other way to calculate with These, for example adding VAT to a total ?
Thanks in advance

admin 3/20/2017

You have two options here

  1. Use a regular List page
  2. Use calculations in SQL query

mbintex author 3/21/2017



You have two options here

  1. Use a regular List page
  2. Use calculations in SQL query


Would like to do the second, but my SQL Query is already quite "enormous".
Sadly I can´t get something like
set @variable
to work - isn´t that possible?
Can´t use the list, because I Need the subsummaries too.