Programming languages are difficult to learn, but not impossible.
Learning programming is easier with these notes.
Here are some notes you will get:
โ Python PDF
โ Git PDF
โ Java PDF
โ SQL PDF
โ JavaScript PDF
โ MongoDB PDF
โ Algorithms PDF
โ And more...
Just:๐
1. Follow me for DM
2. Like and Repost
3. Comment โ FREE โ
๐ฃ๐ฎ๐ถ๐ฑ ๐๐ผ๐๐ฟ๐๐ฒ ๐๐ฅ๐๐ (PART - 1)
1. Artificial Intelligence + Data Analyst
2. Machine Learning + Data Science
3. Cloud Computing + Web Development
4. Ethical Hacking + Hacking
5. Data Analytics + DSA
6. AWS Certified + IBM COURSE
7. Data Science + Deep Learning
8. BIG DATA + SQL COMPLETE COURSE
9. Python + OTHERS
10 MBA + HANDWRITTEN NOTES
(72 Hours only ) Cost About - $500
To get FREE: -
1. Follow (So I can DM you)
2. Like & retweet
3. Reply " Send "
@SaddickAdams As much as Iโm concerned about the prices of coconut Iโm more concerned about the guy drinking the coconut in this tweet
Like ahh wtf
Relax erhh๐๐
Things Every Developer Should Know โ SQL Execution Order.
A SQL query executes its statements in the following order:
1) FROM / JOIN
2) WHERE
3) GROUP BY
4) HAVING
5) SELECT
6) DISTINCT
7) ORDER BY
8) LIMIT / OFFSET
๐ง๐ต๐ฒ ๐๐ฒ๐ฐ๐ต๐ป๐ถ๐พ๐๐ฒ๐ ๐๐ผ๐ ๐ถ๐บ๐ฝ๐น๐ฒ๐บ๐ฒ๐ป๐ ๐ฎ๐ ๐ฒ๐ฎ๐ฐ๐ต ๐๐๐ฒ๐ฝ ๐ต๐ฒ๐น๐ฝ ๐๐ฝ๐ฒ๐ฒ๐ฑ ๐๐ฝ ๐๐ต๐ฒ ๐ณ๐ผ๐น๐น๐ผ๐๐ถ๐ป๐ด ๐๐๐ฒ๐ฝ๐. This is why it's important to know their execution order. ๐ง๐ผ ๐บ๐ฎ๐ ๐ถ๐บ๐ถ๐๐ฒ ๐ฒ๐ณ๐ณ๐ถ๐ฐ๐ถ๐ฒ๐ป๐ฐ๐, ๐ณ๐ผ๐ฐ๐๐ ๐ผ๐ป ๐ผ๐ฝ๐๐ถ๐บ๐ถ๐๐ถ๐ป๐ด ๐๐ต๐ฒ ๐๐๐ฒ๐ฝ๐ ๐ฒ๐ฎ๐ฟ๐น๐ถ๐ฒ๐ฟ ๐ถ๐ป ๐๐ต๐ฒ ๐พ๐๐ฒ๐ฟ๐.
With that in mind, let's take a look at some ๐ผ๐ฝ๐๐ถ๐บ๐ถ๐๐ฎ๐๐ถ๐ผ๐ป ๐๐ถ๐ฝ๐:
๐ญ) ๐ ๐ฎ๐ ๐ถ๐บ๐ถ๐๐ฒ ๐๐ต๐ฒ ๐ช๐๐๐ฅ๐ ๐ฐ๐น๐ฎ๐๐๐ฒ
This clause is executed early, so it's a good opportunity to reduce the size of your data set before the rest of the query is processed.
๐ฎ) ๐๐ถ๐น๐๐ฒ๐ฟ ๐๐ผ๐๐ฟ ๐ฟ๐ผ๐๐ ๐ฏ๐ฒ๐ณ๐ผ๐ฟ๐ฒ ๐ฎ ๐๐ข๐๐ก
Although the FROM/JOIN occurs first, you can still limit the rows. To limit the number of rows you are joining, use a subquery in the FROM statement instead of a table.
๐ฏ) ๐จ๐๐ฒ ๐ช๐๐๐ฅ๐ ๐ผ๐๐ฒ๐ฟ ๐๐๐ฉ๐๐ก๐
The HAVING clause is executed after WHERE & GROUP BY. This means you're better off moving any appropriate conditions to the WHERE clause when you can.
๐ฐ) ๐๐ผ๐ป'๐ ๐ฐ๐ผ๐ป๐ณ๐๐๐ฒ ๐๐๐ ๐๐ง, ๐ข๐๐๐ฆ๐๐ง, ๐ฎ๐ป๐ฑ ๐๐๐ฆ๐ง๐๐ก๐๐ง ๐ณ๐ผ๐ฟ ๐ผ๐ฝ๐๐ถ๐บ๐ถ๐๐ฎ๐๐ถ๐ผ๐ป ๐๐ฒ๐ฐ๐ต๐ป๐ถ๐พ๐๐ฒ๐
It's easy to assume that these would boost performance by minimizing the data set, but this isnโt the case. Because they occur at the end of the query, they make little to no impact on its performance.
If you want to create efficient queries, it's a good idea to understand how things work under the hood otherwise your efforts may be wasted. While these tips work best in most cases, you should consider your unique use case when choosing the best course of action.
~~
Thanks to our partner CodeRabbit who keeps our content free to the community.
๐๐ถ๐ฑ ๐๐ผ๐ ๐ต๐ฒ๐ฎ๐ฟ about CodeRabbit releasing their CLI and providing ๐ณ๐ฟ๐ฒ๐ฒ ๐ฐ๐ผ๐ฑ๐ฒ ๐ฟ๐ฒ๐๐ถ๐ฒ๐๐ ๐ถ๐ป ๐๐ต๐ฒ ๐๐๐?
Check it out: https://t.co/2HlvbMoSQF