Top "Group-by" questions

GROUP BY is a command in the SQL relational database standard for collapsing a group of rows that share common field value(s) into a single row.

Linq order by, group by and order by each group?

I have an object that looks something like this: public class Student { public string Name { get; set; } public int Grade { …

c# linq group-by sql-order-by
How to use group by with union in t-sql

How can I using group by with union in t-sql? I want to group by the first column of a …

sql sql-server tsql group-by union
MySQL Nested Select Query?

Ok, so I have the following query: SELECT MIN(`date`), `player_name` FROM `player_playtime` GROUP BY `player_name` I …

mysql sql select group-by nested
SQL Server GROUP BY datetime ignore hour minute and a select with a date and sum value

I have a table with two fields - datetime and int. I want to do a group by on the …

sql-server datetime select group-by
Group by with union mysql select query

(SELECT COUNT(motorbike.`owner_id`) as count,owner.`name`,transport.`type` FROM transport,owner,motorbike WHERE transport.type='motobike' AND …

mysql sql group-by union
Naming returned columns in Pandas aggregate function?

I'm having trouble with Pandas' groupby functionality. I've read the documentation, but I can't see to figure out how to …

python group-by pandas aggregate-functions
SQL query with avg and group by

I have some problems with writing a SQL query for MySQL. I have a table with the following structure: mysql&…

mysql sql group-by average
Trying to use INNER JOIN and GROUP BY SQL with SUM Function, Not Working

I am not getting my head around this, and wondered if anyone may be able to help me with this. …

sql select join group-by inner-join
SQL to Entity Framework Count Group-By

I need to translate this SQL statement to a Linq-Entity query... SELECT name, count(name) FROM people GROUP by name

sql entity-framework linq-to-entities count group-by
How does Subquery in select statement work in oracle

I have looked all over for an explanation, to how does the subquery in a select statement work and still …

sql oracle select group-by subquery