3 Replies Latest reply on Oct 13, 2017 7:09 AM by niki71

    Jet chart and bind variables

    niki71

      What I like to achieve is a stacked bar chart (jet charts) by using bind variables. Without bind variables everything works fine, see first chart below.

       

      PL/SQL Function Body returning SQL Query looks like this:

       

      begin

      return 'select inst as series, period as label, sum(store) as ges from test where period >= ''02.07.2017'' group by inst, period order by period asc';

      end;

       

      series2.jpg

       

      With bind variable the visibility of stacking is missing (see second chart). PL/SQL Function Body returning SQL Query looks like this, while :P4_NEW_4 is provided by a TextField with value 'INST':

       

      begin

      return 'select '''||:P4_NEW_4||''' as series, period as label, sum(store) as ges from test where period >= ''02.07.2017'' group by '''||:P4_NEW_4||''', period order by period asc';

      end;

       

      series1.jpg

       

      Apex Version is 5.1.2. Any Ideas?