Skip to Content
avatar image
Former Member

Counting rows

I have created a query that generates a certain number of customers based on their sales volume. I would like to create a variable that would count the number of customers that are returned from this query. Can anyone give me some help?

Thanks

Brian

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • Best Answer
    avatar image
    Former Member
    Feb 07, 2006 at 06:04 AM

    Hi Brian,

    can u give me u r Query structure?what r u having in rows and columns?do u have any structures?y i am asking is,i had similar kind of requirement and by using formulas,properties of kf and chars...we solved it...

    regards

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi Brain,

      How u r filtering customers based on variance? like...if varince is > or < particular value?

      for example in u r filtering customers if variance is > 0.then create a new formula ( 'Variance' >= 0 ).and set calculate result as Summmation.It displays total no of customers whose variance is >0...and set Suppress result rows 'never' for Customer.

      Hope this helps

  • Feb 06, 2006 at 03:54 PM

    Hi Brian,

    If you have a Counter key figure in your InfoProvider, you can use this in the query definition. In its properties Suppress the Single values and Calculate Results as Summation. This should work for simple scenarios...what else do you have in your query definition?

    Add comment
    10|10000 characters needed characters exceeded

    • Hi Brian,

      You could try doing the same by creating a formula = 1. If you just have Customer in drilldown, it will work fine. If you add another char, then since there will be 1 for each row, it will not give you the number of customers.

      Hope this helps...

  • avatar image
    Former Member
    Feb 06, 2006 at 04:03 PM

    hi Brian,

    take a look this 'how to count the occurence...' doc hope it helps.

    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/7e58e690-0201-0010-fd85-a2f29a41c7af

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Feb 07, 2006 at 01:46 PM

    Hi Brian, Create a counter KF and write a conditions in the update rules based on your requirements and then try to create a variable.

    regs,

    MBA

    Add comment
    10|10000 characters needed characters exceeded