ID | artiste | album | year |
---|---|---|---|
1 | Rod Stewart | Maggie May | 1973 |
2 | New Order | Substance | 1987 |
3 | Nirvana | Smell Like Teen Spirit | 1992 |
In a database table, we can use select count to retrieve the number of records in a table.
Syntax: select count(*) from table_name
select count(*) from artiste
We can also use the syntax where we count a particular column such as id or album.
select count(id) from artiste
select count(album) from artiste