regarding Group by
-
Hi, if we are trying to add the several columns in select statement without using Aggregate functions and only one condition in group by. how can we do that ??
-
Hi, if we are trying to add the several columns in select statement without using Aggregate functions and only one condition in group by. how can we do that ??
I'm not sure I understand you. Can you throw some SQL my way...
"When you have made evil the means of survival, do not expect men to remain good. Do not expect them to stay moral and lose their lives for the purpose of becoming the fodder of the immoral. Do not expect them to produce, when production is punished and looting rewarded. Do not ask, `Who is destroying the world?' You are."
-Atlas Shrugged, Ayn Rand -
Hi, if we are trying to add the several columns in select statement without using Aggregate functions and only one condition in group by. how can we do that ??
praveenanand wrote:
if we are trying to add the several columns in select statement without using Aggregate functions and only one condition in group by.
You can't. Each column not specified in the GROUP BY clause must be part of an aggregate on the SELECT. If you think about what it is doing you will see why.
Upcoming FREE developer events: * Developer Day Scotland My website | blog