Disable data labels

(5 posts) (2 voices)

Tags:

No tags yet.

  1. Dev, Member

    Hi,

    I'm using a Stacked Column Chart in my report, and the data labels on the bars are cluttered. I tried using chart options to disable them , but they still show.

    Could you please help me with the correct way to remove or hide these labels?

    So far used the below commands

    SELECT 'dbr.chart.options', 'datalabels.display', 'false';
    SELECT 'dbr.chart.options', 'annotations.alwaysOutside', 'false';
    SELECT 'dbr.chart.options', 'annotations.textStyle.color', 'transparent';

    Pls guide me on this.

  2. myDBR Team, Key Master

    The options you are using seem to be for Google Charts, which is why they are not working as myDBR does not use Google Charts.

    What is the chart engine you are using ChartDirector or Chart.js?

    Assuming you are using ChartDirector, you can control the values visibility with the showValues-option.

    To disable the values altogether:

    SELECT 'dbr.chart.options', 'showValues', 0;

    To show only total values:

    SELECT 'dbr.chart.options', 'showValues', 'total';

    To show only the data values:

    SELECT 'dbr.chart.options', 'showValues', 'data';

    --
    myDBR Team

  3. Dev, Member

    Hi,

    I did use the showvalues 0 command, but it still shows the values. Below are the commands I used:

    SELECT 'dbr.chart', 'StackedColumn', CONCAT('Daily Comparison: ', DATE_FORMAT(inStartDate, '%m/%d/%Y'), ' - ', DATE_FORMAT(inEndDate, '%m/%d/%Y')), 1500, 500;
    SELECT 'dbr.chart.options', 'chartjs';
    SELECT 'dbr.chart.options', 'showvalues', 0;

    Is there anything I should change to make this work?

  4. myDBR Team, Key Master

    The option:

    select 'dbr.chart.options', 'showValues', 0;

    should disable the data labels.

    Please open a support ticket with SQL export of your report.

    --
    myDBR Team

  5. Dev, Member

    Hi,

    Sent support request mail with the subject 'Disable Data Labels - https://mydbr.com/forums/topic.php?id=3374', Pls check and update.

    Thank you,
    Shiva S


Reply

You must log in to post.