About 52 results
Open links in new tab
  1. How to count occurrences of a column value efficiently in SQL?

    How to count occurrences of a column value efficiently in SQL? Asked 16 years, 1 month ago Modified 1 year, 8 months ago Viewed 711k times

  2. MySQL - Using COUNT(*) in the WHERE clause - Stack Overflow

    Nov 19, 2008 · SELECT DISTINCT gid FROM `gd` WHERE COUNT(*) > 10 ORDER BY lastupdated DESC Is there a way to do this without using a (SELECT...) in the WHERE clause …

  3. In SQL, what's the difference between count (column) and count ...

    Sep 12, 2008 · The COUNT (*) sentence indicates SQL Server to return all the rows from a table, including NULLs. COUNT (column_name) just retrieves the rows having a non-null value on …

  4. SQL count rows in a table - Stack Overflow

    Mar 7, 2015 · I need to send a SQL query to a database that tells me how many rows there are in a table. I could get all the rows in the table with a SELECT and then count them, but I don't like …

  5. sql - Is it possible to specify condition in Count ()? - Stack Overflow

    607 Is it possible to specify a condition in Count()? I would like to count only the rows that have, for example, "Manager" in the Position column.

  6. sql - count (*) vs count (column-name) - which is more correct?

    Jun 9, 2010 · To be exact, COUNT (column) counts rows in which values of column is not NULL, whereas COUNT (*) counts all rows of the table.

  7. sql - How to use count and group by at the same select statement ...

    Apr 27, 2010 · I have an SQL SELECT query that also uses a GROUP BY, I want to count all the records after the GROUP BY clause filtered the resultset. Is there any way to do this directly …

  8. sql - COUNT (*) vs. COUNT (1) vs. COUNT (pk): which is better?

    Apr 26, 2010 · COUNT(1) - Will not fetch any row, instead count is called with a constant value of 1 for each row in the table when the WHERE matches. COUNT(PK) - The PK in Oracle is …

  9. sql - Selecting COUNT (*) with DISTINCT - Stack Overflow

    656 In SQL Server 2005 I have a table cm_production that lists all the code that's been put into production. The table has a ticket_number, program_type, program_name and push_number …

  10. sql - ¿Cuál es la diferencia entre COUNT (*), COUNT (1) y COUNT ...

    Jan 11, 2018 · Siempre me he preguntado cuál es la diferencia entre estas tres formas de usar COUNT en SQL (tampoco sé si hay diferencia según el manejador de base de datos que se …