Home

barchart Ignoring the ymin and ymax values

%3CLINGO-SUB%20id%3D%22lingo-sub-739251%22%20slang%3D%22en-US%22%3Ebarchart%20Ignoring%20the%20ymin%20and%20ymax%20values%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-739251%22%20slang%3D%22en-US%22%3E%3CP%3EI%20know%20there%20is%20an%20open%20post%20but%20even%20that%20isn't%20closed.%20Along%20with%20these%20params%20many%20other%20properties%20also%20doesn't%20seem%20to%20work.%20e.g.%20legend%3C%2FP%3E%0A%3CP%3EMy%20query%20%3A%3C%2FP%3E%0A%3CDIV%3E%0A%3CDIV%3E%3CSPAN%3EAzureDiagnostics%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%3CSPAN%3E%7C%20%3C%2FSPAN%3E%3CSPAN%3Ewhere%3C%2FSPAN%3E%3CSPAN%3E%20replicationProviderName_s%20%3D%3D%20%3C%2FSPAN%3E%3CSPAN%3E%22A2A%22%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%3CSPAN%3E%7C%20%3C%2FSPAN%3E%3CSPAN%3Ewhere%3C%2FSPAN%3E%3CSPAN%3E%20isnotempty(name_s)%20%3C%2FSPAN%3E%3CSPAN%3Eand%3C%2FSPAN%3E%3CSPAN%3E%20isnotnull(name_s)%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%3CSPAN%3E%7C%20%3C%2FSPAN%3E%3CSPAN%3Eextend%3C%2FSPAN%3E%3CSPAN%3E%20RPO%20%3D%20case(rpoInSeconds_d%20%26lt%3B%3D%20%3C%2FSPAN%3E%3CSPAN%3E900%3C%2FSPAN%3E%3CSPAN%3E%2C%20%3C%2FSPAN%3E%3CSPAN%3E%22%26lt%3B15Min%22%3C%2FSPAN%3E%3CSPAN%3E%2C%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%3CSPAN%3ErpoInSeconds_d%20%26lt%3B%3D%20%3C%2FSPAN%3E%3CSPAN%3E1800%3C%2FSPAN%3E%3CSPAN%3E%2C%20%3C%2FSPAN%3E%3CSPAN%3E%2215-30Min%22%3C%2FSPAN%3E%3CSPAN%3E%2C%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%3CSPAN%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%3C%2FSPAN%3E%3CSPAN%3E%22%26gt%3B30Min%22%3C%2FSPAN%3E%3CSPAN%3E)%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%3CSPAN%3E%7C%20%3C%2FSPAN%3E%3CSPAN%3Esummarize%3C%2FSPAN%3E%3CSPAN%3E%20hint.strategy%3Dpartitioned%20arg_max(TimeGenerated%2C%20*)%20%3C%2FSPAN%3E%3CSPAN%3Eby%3C%2FSPAN%3E%3CSPAN%3E%20name_s%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%3CSPAN%3E%7C%20%3C%2FSPAN%3E%3CSPAN%3Eproject%3C%2FSPAN%3E%3CSPAN%3E%20name_s%20%2C%20RPO%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%3CSPAN%3E%7C%20%3C%2FSPAN%3E%3CSPAN%3Esummarize%3C%2FSPAN%3E%3CSPAN%3E%20Count%20%3D%20%3C%2FSPAN%3E%3CSPAN%3Ecount%3C%2FSPAN%3E%3CSPAN%3E()%20%3C%2FSPAN%3E%3CSPAN%3Eby%3C%2FSPAN%3E%3CSPAN%3E%20RPO%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%3CSPAN%3E%7C%20%3C%2FSPAN%3E%3CSPAN%3Erender%3C%2FSPAN%3E%3CSPAN%3E%20barchart%20with%20(ymin%3D0)%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%3C%2FDIV%3E%0A%3CDIV%3E%3CSPAN%3EMy%20output%20%3A%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%3CSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20279px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F122283i185BD5964C461F95%2Fimage-dimensions%2F279x196%3Fv%3D1.0%22%20width%3D%22279%22%20height%3D%22196%22%20alt%3D%22table%20data.PNG%22%20title%3D%22table%20data.PNG%22%20%2F%3E%3C%2FSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F122284iE30DDF9DF2BE1F4A%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22output.PNG%22%20title%3D%22output.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%3CSPAN%3EExpected%20output%3A%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%3CSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20344px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F122286iC1D56FC902F1AA2D%2Fimage-size%2Fmedium%3Fv%3D1.0%26amp%3Bpx%3D400%22%20alt%3D%22rpo.PNG%22%20title%3D%22rpo.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%26nbsp%3B%3C%2FDIV%3E%0A%3CDIV%3E%3CSPAN%3EI%20tried%20changing%20all%20the%20options%2C%20but%20it%20still%20looks%20like%20above.%26nbsp%3B%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%3CSPAN%3EAlso%20how%20can%20i%20fix%20the%20x%20axis%20to%20show%203%20fix%20values%20i.e.%20%26lt%3B15%2C%2015-20%2C%20%26gt%3B30%20always%3C%2FSPAN%3E%3C%2FDIV%3E%0A%3CDIV%3E%0A%3CDIV%20class%3D%22k-grid-header%22%3E%0A%3CDIV%20class%3D%22k-grid-header-wrap%20k-auto-scrollable%22%20data-role%3D%22resizable%22%3E%26nbsp%3B%3C%2FDIV%3E%0A%3C%2FDIV%3E%0A%3C%2FDIV%3E%0A%3C%2FDIV%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-739251%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EAzure%20Log%20Analytics%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EQuery%20Language%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-739429%22%20slang%3D%22en-US%22%3ERe%3A%20barchart%20Ignoring%20the%20ymin%20and%20ymax%20values%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-739429%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F371526%22%20target%3D%22_blank%22%3E%40hsaini007%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EWould%20this%20help%3F%3C%2FP%3E%0A%3CPRE%3EAzureDiagnostics%0A%20%20%20%20%7C%20where%20replicationProviderName_s%20%3D%3D%20%22A2A%22%0A%20%20%20%20%7C%20where%20isnotempty(name_s)%20and%20isnotnull(name_s)%0A%20%20%20%20%7C%20extend%20RPO%20%3D%20case(%0A%20%20%20%20%20%20%20%20%20%20%20%20rpoInSeconds_d%20%26lt%3B%3D%20100%2C%20%20%22%26lt%3B15Min%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20rpoInSeconds_d%20%26lt%3B%3D%201000%2C%20%2215-30Min%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%26gt%3B30Min%22)%0A%20%20%20%20%7C%20summarize%20hint.strategy%3Dpartitioned%20arg_max(TimeGenerated%2C%20*)%20by%20name_s%0A%20%20%20%20%7C%20project%20comp_list%20%3D%20name_s%20%2C%20RPO%0A%20%20%20%20%7C%20summarize%20count(comp_list)%20by%20RPO%2C%20comp_list%0A%7C%20render%20barchart%20kind%3Dstacked%20%3C%2FPRE%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-742080%22%20slang%3D%22en-US%22%3ERe%3A%20barchart%20Ignoring%20the%20ymin%20and%20ymax%20values%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-742080%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F239477%22%20target%3D%22_blank%22%3E%40Clive%20Watson%3C%2FA%3E%26nbsp%3B%3A%20thanks%20for%20your%20reply%20but%20the%20output%20is%20still%20not%20as%20expected.%3C%2FP%3E%0A%3CP%3EElaborating%20the%20context%20here%2C%20I%20am%20trying%20to%20group%20the%20occurences%20based%20on%20time%20range%20showing%20the%20count%20of%20occurrences%20per%20range.%3C%2FP%3E%0A%3CP%3EE.g.%20How%20many%20vm's%20have%20RPO%20time%20%26lt%3B15%20min%2C%20how%20many%20between%2015-30min%20and%20rest.%26nbsp%3B%26nbsp%3B%3C%2FP%3E%0A%3CP%3EThe%20output%20of%20the%20updated%20query%20looks%20below.%20unstacking%20just%20result%20in%20a%20bar%20of%20height%201.%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F122518iC7EF1BA0F3460957%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22new%20output.PNG%22%20title%3D%22new%20output.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-742115%22%20slang%3D%22en-US%22%3ERe%3A%20barchart%20Ignoring%20the%20ymin%20and%20ymax%20values%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-742115%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F371526%22%20target%3D%22_blank%22%3E%40hsaini007%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIf%20its%20just%20a%20count%2C%20wouldn't%20this%20be%20enough%3F%3C%2FP%3E%0A%3CPRE%3EAzureDiagnostics%0A%20%20%20%20%7C%20where%20replicationProviderName_s%20%3D%3D%20%22A2A%22%0A%20%20%20%20%7C%20where%20isnotempty(name_s)%20and%20isnotnull(name_s)%0A%20%20%20%20%7C%20extend%20RPO%20%3D%20case(%0A%20%20%20%20%20%20%20%20%20%20%20%20rpoInSeconds_d%20%26lt%3B%3D%20100%2C%20%20%22%26lt%3B15Min%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20rpoInSeconds_d%20%26lt%3B%3D%20500%2C%20%2215-30Min%22%2C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%22%26gt%3B30Min%22)%0A%7C%20summarize%20count()%20by%20RPO%20%2C%20name_s%0A%7C%20render%20barchart%3C%2FPRE%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F122522i7EA5CA24ED92FAE5%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22Annotation%202019-07-08%20104957.jpg%22%20title%3D%22Annotation%202019-07-08%20104957.jpg%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3Eor%20(hide%20the%20name_s)%3C%2FP%3E%0A%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20944px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F122523iEA188281BC062297%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22Annotation%202019-07-08%20105030-2.jpg%22%20title%3D%22Annotation%202019-07-08%20105030-2.jpg%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fportal.loganalytics.io%2FDemo%3Fq%3DH4sIAAAAAAAAA4WOwQqCQBRF90H%252F8JiVQoEW7jIQ2rSopD5ApvFRA%252FpG3oyV4cdnioug6C7vPRdO8qwZN1peyFinlZ1OoEsL9ysyAmNVaCWdNpSyuekceS9LzCzEMYhkkYhPXlsyDsvKNR71nA%252BS8qGmuijGdnzhw2G3H9MDxKCkRW9YxnBltnRCZSi3WQ6rGMIgmAGIVRjtNInZPzx64yKM5svgC%252F8rYj3gnWcLti5LyfqJoExNzvPh3PTG75E7fWQ4S1ZXyW46eQHlRRRlUAEAAA%253D%253D%26amp%3Btimespan%3DP1D%22%20target%3D%22_blank%22%20rel%3D%22nofollow%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3EGo%20to%20Log%20Analytics%20and%20Run%20Query%3C%2FA%3E%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-742262%22%20slang%3D%22en-US%22%3ERe%3A%20barchart%20Ignoring%20the%20ymin%20and%20ymax%20values%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-742262%22%20slang%3D%22en-US%22%3E%3CP%3EHey%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F239477%22%20target%3D%22_blank%22%3E%40Clive%20Watson%3C%2FA%3E%26nbsp%3B%3A%20The%20problem%20remains%20the%20same.%20due%20to%20yMin%20not%20being%20set%20to%200%20I%20can%20never%20see%20the%20bar%20for%20the%20third%20range.%26nbsp%3B%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F122531i7F18055905A2BEC3%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22new%20data.PNG%22%20title%3D%22new%20data.PNG%22%20%2F%3E%3C%2FSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20999px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F122532i605B173181855841%2Fimage-size%2Flarge%3Fv%3D1.0%26amp%3Bpx%3D999%22%20alt%3D%22new%20gaph.PNG%22%20title%3D%22new%20gaph.PNG%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E
hsaini007
Microsoft

I know there is an open post but even that isn't closed. Along with these params many other properties also doesn't seem to work. e.g. legend

My query :

AzureDiagnostics
    | where replicationProviderName_s == "A2A"
    | where isnotempty(name_s) and isnotnull(name_s)
    | extend RPO = case(rpoInSeconds_d <= 900, "<15Min",
    rpoInSeconds_d <= 1800, "15-30Min",
    ">30Min")
    | summarize hint.strategy=partitioned arg_max(TimeGenerated, *) by name_s
    | project name_s , RPO
    | summarize Count = count() by RPO
| render barchart with (ymin=0)
 
 
My output :
table data.PNGoutput.PNG
Expected output:
rpo.PNG
 
I tried changing all the options, but it still looks like above. 
Also how can i fix the x axis to show 3 fix values i.e. <15, 15-20, >30 always
 
4 Replies

@hsaini007 

 

Would this help?

AzureDiagnostics
    | where replicationProviderName_s == "A2A"
    | where isnotempty(name_s) and isnotnull(name_s)
    | extend RPO = case(
            rpoInSeconds_d <= 100,  "<15Min",
            rpoInSeconds_d <= 1000, "15-30Min",
                                    ">30Min")
    | summarize hint.strategy=partitioned arg_max(TimeGenerated, *) by name_s
    | project comp_list = name_s , RPO
    | summarize count(comp_list) by RPO, comp_list
| render barchart kind=stacked 

@Clive Watson : thanks for your reply but the output is still not as expected.

Elaborating the context here, I am trying to group the occurences based on time range showing the count of occurrences per range.

E.g. How many vm's have RPO time <15 min, how many between 15-30min and rest.  

The output of the updated query looks below. unstacking just result in a bar of height 1.new output.PNG

@hsaini007 

 

If its just a count, wouldn't this be enough?

AzureDiagnostics
    | where replicationProviderName_s == "A2A"
    | where isnotempty(name_s) and isnotnull(name_s)
    | extend RPO = case(
            rpoInSeconds_d <= 100,  "<15Min",
            rpoInSeconds_d <= 500, "15-30Min",
                                    ">30Min")
| summarize count() by RPO , name_s
| render barchart

Annotation 2019-07-08 104957.jpg

 

or (hide the name_s)

Annotation 2019-07-08 105030-2.jpg

 

 

Go to Log Analytics and Run Query

 

 

Hey @Clive Watson : The problem remains the same. due to yMin not being set to 0 I can never see the bar for the third range. new data.PNGnew gaph.PNG

Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
46 Replies
Security Community Webinars
Valon_Kolica in Security, Privacy & Compliance on
13 Replies
flashing a white screen while open new tab
Deleted in Discussions on
14 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
29 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
Extentions Synchronization
Deleted in Discussions on
3 Replies