command dbr.calc got error ?

(7 posts) (2 voices)

Tags:

No tags yet.

  1. spyhunter88, Member

    Hi,

    I have use some dbr.calc and found it does not calculate or does it but wrong value. That's my export:
    select 'dbr.sum', 'SFO', 'SA', 'CA', 'Other_IL', '[Ex]'; select 'dbr.calc', 'GP_calc', '[SA]-[CA]'; select 'dbr.calc', 'GP_Others_calc', '[GP_calc]+[Other_IL]'; select 'dbr.calc', 'NI_calc', '[GP_Others_calc]-[Ex]';

    select 'dbr.colstyle', 'SFO', '[background-color: #CCEEFF;font-weight: bold;]%.0f'; select 'dbr.colstyle', 'GP_Others_calc', '[background-color: #CCEEFF;font-weight: bold;]%.0f'; select 'dbr.colstyle', 'Ex', '[background-color: #CCEEFF;font-weight: bold;]%.0f'; select 'dbr.colstyle', 'NI_calc', '[background-color: #CCEEFF;font-weight: bold;]%.0f'; select 'dbr.colstyle', 'SA', '%.0f'; select 'dbr.colstyle', 'CA', '%.0f'; select 'dbr.colstyle', 'Other_IL', '%.0f'; select 'dbr.colstyle', 'GP_calc', '[color: green]%.0f; ;[color: red;]%.0f';

    select 'F1' as 'Company', 0.000000 as 'SFO[SFO]', 0.000000 as 'SA[SA]', 0.000000 as 'CA[CA]', null as 'Gross Profit[GP_calc]', 0.000000 as 'Other I/L[Other_IL]', null as 'GP & Others[GP_Others_calc]', -3403.938500 as 'Expense[Ex]', null as 'NI[NI_calc]' union all select 'F2', 0.000000, 0.000000, -1818.011300, null, -10559.428000, null, -12950.043100, null union all select 'F3', 0.000000, 0.000000, -15495.348800, null, 0.000000, null, -1417.640100, null union all select 'F4', 0.000000, 0.000000, -12600.000000, null, 0.000000, null, 0.000000, null union all select 'F5', 0.000000, 0.000000, 9959.366000, null, 0.000000, null, -922.138700, null;
    If I remove the dbr.colstyle block, the missing value are zero and others result are the same. Please fix it soon.

    Thanks,

  2. myDBR Team, Key Master

    Could you be more specific what is the actual problem? What does not calculate or what has wrong value?

    --
    myDBR Team

  3. spyhunter88, Member

    You can see this in this picture.

    The Summary of Gross Profit and NI columns are missing. If I remove the format (dbr.colstyle), the value will be zero. I am using Version 4.3.2 build 2536.

    Please confirm that's not my personal environment bug. :D

  4. myDBR Team, Key Master

    myDBR will now automatically use parenthesis in formulas. You can run the updater.

    --
    myDBR Team

  5. spyhunter88, Member

    Nice,

    The issue is fixed.

    Thanks,

  6. spyhunter88, Member

    Hi,

    I re-open this topic because the issue is not fixed completely in my build (4.3.4 (build 2569)). I saw another issue when the total is zero, it's show nothing rather than "0" value. If the total is not zero, it appears ok.
    select 'dbr.sum', 'SFO', 'SA', 'CA', 'Other_IL', '[Ex]'; select 'dbr.calc', 'GP_calc', '[SA]-[CA]'; select 'dbr.calc', 'GP_Others_calc', '[GP_calc]+[Other_IL]'; select 'dbr.calc', 'NI_calc', '[GP_Others_calc]-[Ex]';

    select 'dbr.colstyle', 'SFO', '[background-color: #CCEEFF;font-weight: bold;]%.0f'; select 'dbr.colstyle', 'GP_Others_calc', '[background-color: #CCEEFF;font-weight: bold;]%.0f'; select 'dbr.colstyle', 'Ex', '[background-color: #CCEEFF;font-weight: bold;]%.0f'; select 'dbr.colstyle', 'NI_calc', '[background-color: #CCEEFF;font-weight: bold;]%.0f'; select 'dbr.colstyle', 'SA', '%.0f'; select 'dbr.colstyle', 'CA', '%.0f'; select 'dbr.colstyle', 'Other_IL', '%.0f'; select 'dbr.colstyle', 'GP_calc', '[color: green]%.0f; ;[color: red;]%.0f';

    select 'F1' as 'Company', 0.000000 as 'SFO[SFO]', 0.000000 as 'SA[SA]', 0.000000 as 'CA[CA]', null as 'Gross Profit[GP_calc]', 0.000000 as 'Other I/L[Other_IL]', null as 'GP & Others[GP_Others_calc]', -3120.000000 as 'Expense[Ex]', null as 'NI[NI_calc]' union all select 'F2', 0.000000, 0.000000, 0.000000, null, 0.000000, null, -3688.000000, null union all select 'F3', 0.000000, 0.000000, 0.000000, null, 0.000000, null, -414.000000, null union all select 'F4', 0.000000, 0.000000, 8277.000000, null, 0.000000, null, -1055.000000, null ;

    You'll see in the picture, the NI total is missing.

    Thanks,

  7. myDBR Team, Key Master

    The formatting issue is now fixed.

    --
    myDBR Team


Reply

You must log in to post.