Friday, February 21, 2020

Answer for why do we need group by command at the end of this query??

https://365datascience.com/dwqa-answer/answer-for-why-do-we-need-group-by-command-at-the-end-of-this-query/ -

Hi Kane!

Thanks for reaching out!

In this query, the GROUP BY clause allows us to obtain output per employee number. In other words, if we don’t include it, then MySQL will only display an output for the first employee number as obtained by the SQL optimiser and will disregard the rest. That’s how MySQL will behave by default.

Be adding a GROUP BY clause, we designate that we want the output to be separated by employee number.

Hope this helps.
Best,
Martin




#365datascience #DataScience #data #science #365datascience #BigData #tutorial #infographic #career #salary #education #howto #scientist #engineer #course #engineer #MachineLearning #machine #learning #certificate #udemy

No comments:

Post a Comment