G
Guest
Let's say I want to count the number of order lines for every order. So I
have an order that has 6 lines on it. I want to count the order as a unique
identity but count all six lines so the query would return
countofORDERS = 1
countofLINES = 6
but what is happening is this
countofORDERS = 6
countofLINES = 6
It's counting the order # 6 times even though it's the same number.
is there such thing as a count distinct or something similiar? I could not
find one.
have an order that has 6 lines on it. I want to count the order as a unique
identity but count all six lines so the query would return
countofORDERS = 1
countofLINES = 6
but what is happening is this
countofORDERS = 6
countofLINES = 6
It's counting the order # 6 times even though it's the same number.
is there such thing as a count distinct or something similiar? I could not
find one.