CDEFC with cacti aggregate is disappearing after adding to a tree

I have created an aggregate graph from simple 2 line graphs and chose to display only the total value. The aggregate graph is created under the "aggregate graphs" section under management everything is cool and working accordingly, I can see the graph properly under the preview tab in "aggregate graphs" section.

However, when I add the aggregated graph under any graph tree, the whole RRD for the aggregated graph changes and the graph cannot show the total value. After I checked I realised below.

Here is the graph rrd before adding to a tree:

/bin/rrdtool graph - \
--imgformat=PNG \
--start='-86400' \
--end='-300' \
--title='Total Online Users' \
--base='1000' \
--height='150' \
--width='650' \
--alt-autoscale-max \
--lower-limit='0' \
--units-exponent='0' \
--vertical-label='Online Users' \
--slope-mode \
--font TITLE:10: \
--font AXIS:7: \
--font LEGEND:8: \
--font UNIT:7: \
DEF:a='/usr/share/cacti/rra/xxxxxxxxxxxxxxxx.rrd':'dsl_user_input':AVERAGE \
DEF:b='/usr/share/cacti/rra/yyyyyyyyyyyyyyyy.rrd':'time':AVERAGE \
CDEF:cdefa='a,0,*' \
CDEF:cdefb='b,0,*' \
CDEF:cdefc='TIME,1533625072,GT,a,a,UN,0,a,IF,IF,TIME,1533625072,GT,b,b,UN,0,b,IF,IF,+' \
LINE2:cdefa#0000FFFF:''  \
LINE2:cdefb#0000FFFF:''  \
GPRINT:cdefc:LAST:'Total Users\:%8.0lf'  \
LINE2:cdefc#0000FFFF:''  \
GPRINT:cdefc:MIN:'Min Users\: %8.0lf'  \
GPRINT:cdefc:MAX:'Max Users\: %8.0lf\n'

As you can see above, cdefc is the total value and it is exactly as what I need.

And here is the graph rrd after adding to a tree:

/bin/rrdtool graph - \
--imgformat=PNG \
--start='-86400' \
--end='-300' \
--title='Total Online Users' \
--base='1000' \
--height='150' \
--width='650' \
--alt-autoscale-max \
--lower-limit='0' \
--units-exponent='0' \
--vertical-label='Online Users' \
--slope-mode \
--font TITLE:10: \
--font AXIS:7: \
--font LEGEND:8: \
--font UNIT:7: \
DEF:a='/usr/share/cacti/rra/xxxxxxxxxxxxxxxx.rrd':'dsl_user_input':AVERAGE \
DEF:b='/usr/share/cacti/rra/yyyyyyyyyyyyyyyy.rrd':'time':AVERAGE \
CDEF:cdefa='a,0,*' \
CDEF:cdefb='b,0,*' \
LINE2:cdefa#0000FFFF:''  \
LINE2:cdefb#0000FFFF:''

Basically, the cdefc is lost after adding to a tree.