<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi Oliver<div class=""><br class=""></div><div class="">I’m afraid you’ll always need a DEF from somewhere. I’ve done plenty of workarounds like this, including having an empty rrdfile that is never updated. Usually I end up doing something like this to get just a 0 value...</div><div class=""><br class=""></div><div class=""><font face="Courier New" class="">DEF:foo=/some/empty/rrdfile.rrd:foo:AVERAGE</font></div><div class=""><font face="Courier New" class="">CDEF:myval=foo,POP,0</font></div><div class=""><br class=""></div><div class="">Hope that helps :)</div><div class=""><br class=""></div><div class="">Cheers,</div><div class="">  Jacques</div><div class=""><br class=""><div><blockquote type="cite" class=""><div class="">On 14 Feb 2017, at 20:49, Olivier Doucet <<a href="mailto:webmaster@ajeux.com" class="">webmaster@ajeux.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">Hi,<div class=""><br class=""><div class="gmail_extra"><br class=""><div class="gmail_quote">2017-02-14 19:44 GMT+01:00 SolarMan <span dir="ltr" class=""><<a href="mailto:hans@vega.demon.nl" target="_blank" class="">hans@vega.demon.nl</a>></span>:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello Olivier,<br class="">
The error message is confusing and should actually read:<br class="">
rrdtool.OperationalError: rpn expressions without DEF or CDEF variables are<br class="">
not supported<br class="">
as it does in other cases.<br class="">
The meaning is clear: you must use a DEF or CDEF in your CDEF definition.<br class="">
Regards,<br class="">
hans<br class=""></blockquote><div class=""><br class=""></div><div class="">Thank you Hans for your quick response. I understand the documentation is wrong then.</div><div class=""><br class=""></div><div class="">Any idea how to easily create a DEF with 0 value all along ? I'm using it in a automatized script that write the whole 'rrdtool graph' line, and when original DEF file is not present, I would like to replace it with 0 to keep the same logic.</div><div class=""><br class=""></div><div class="">Olivier</div><div class=""><br class=""></div><div class=""><br class=""></div></div></div></div></div>
_______________________________________________<br class="">rrd-users mailing list<br class=""><a href="mailto:rrd-users@lists.oetiker.ch" class="">rrd-users@lists.oetiker.ch</a><br class="">https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users<br class=""></div></blockquote></div><br class=""></div></body></html>