2.Count

<PLEASE USE THIS TEMPLATE TO HELP YOU CREATE A GREAT POST!>

<Below this line, add a link to the EXACT exercise that you are stuck at.>

<Below this line, in what way does your code behave incorrectly? Include ALL error messages.>

<In this course, it often helps to include a screenshot of your whole web browser – that lets everyone see what you see. If you wish to include a screenshot, add it below this line.>

<If you wish to copy/paste in your code, you can use this next section. This will allow others to copy/paste your code for testing – something that they won’t be able to do with just a screenshot.>

```

Replace this line with your code.

IN the 2.Count

<do not remove the three backticks above>
The code"**SELECT price, COUNT(*) FROM fake_apps**
**GROUP BY price**;"

Why used **COUNT(*)** not **COUNT(price)**?

@microsolver95620
With count(*) you are counting the rows indifferent of the Value

With count(price) you must know that the count aggregate only counts the non-null values

Please read
found with google search
== discussion / opinion ==
sqlite count(*) vs count(column)
http://stackoverflow.com/questions/1400078/is-it-possible-to-specify-condition-in-count

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.