Hey there! 👋 For more interesting content, tutorials, and updates, Feel free to connect with me on Instagram Handles :- @createwithchirag - instagram.com/createwithchirag/ @learn.with.chirag - instagram.com/learn.with.chirag/ LinkedIn: www.linkedin.com/in/chirag-sehgal-9200111b8/ Let's stay connected and keep the creativity flowing! 💡
Great explanation! I was trying a new approach and came across this query, the runtime of 197ms, beating 87.71% SELECT a1.machine_id, ROUND(AVG(a2.timestamp - a1.timestamp), 3) AS processing_time FROM Activity a1 JOIN Activity a2 ON a1.machine_id = a2.machine_id AND a1.process_id = a2.process_id AND a1.activity_type = 'start' AND a2.activity_type = 'end' GROUP BY a1.machine_id;
sir i want ot be data analyst..guide me plz.. what topics what project where to find job where to practice and which topic problems which oyutube channel or source is good
For becoming a good Data Analyst , these are the steps you need to follow- 1) Understand Business - how they work , how data is important for them , which type of data can increase their revenue. 2) Learn Relevant Skills & tools - excell , SQL , Power BI or tabelue , also research for tools which are in demand these days and learn them too. 3) Profile Building - Make real time projects , take data from websites like kaggle , also take data from some real business and try to implement them , make dashboard ....make advance projects , see the people already in this industry , what projects are they making.... make ATS Friendly resume , do internship or freelancing projects 4) Build Network & Apply for Job - Use Platforms like Linked In , Twitter ...showcase your skills their and tag recruiters from your dream company....if your work will be good they will definitely reach back to you. At last apply for 100s of jobs , you will get reply from atleast 4-5 of them.
The "ON" clause in this query specifies the conditions for joining records from the Activity table with itself (a1 and a2 instances) based on matching process_id and machine_id, and ensuring that the activities are ordered correctly in terms of time. If its still not clear , I will request you to dry run the query once. And no need to worry , you will get the clarity of concept when you will complete the playlist. Start from video 1 and go till video 50. You will be a champ in SQL.💯
It's called self join. We created two instances of a single table in order to return the required result. Please do watch all the videos you will get this concept more clearly! Keep Learning 💯
Hey there! 👋 For more interesting content, tutorials, and updates, Feel free to connect with me on
Instagram Handles :-
@createwithchirag - instagram.com/createwithchirag/
@learn.with.chirag - instagram.com/learn.with.chirag/
LinkedIn: www.linkedin.com/in/chirag-sehgal-9200111b8/
Let's stay connected and keep the creativity flowing! 💡
people dont know how underrated this guy is...... you deserve a lot bro
Great explanation! I was trying a new approach and came across this query, the runtime of 197ms, beating 87.71%
SELECT a1.machine_id,
ROUND(AVG(a2.timestamp - a1.timestamp), 3) AS processing_time
FROM Activity a1
JOIN Activity a2
ON a1.machine_id = a2.machine_id
AND a1.process_id = a2.process_id
AND a1.activity_type = 'start'
AND a2.activity_type = 'end'
GROUP BY a1.machine_id;
Another Problem made easy, thanks.
Glad to help❤️
Nice explanation bhaiya
Thanks brother ! Keep Learning :)
sir i want ot be data analyst..guide me plz..
what topics
what project
where to find job
where to practice and which topic problems
which oyutube channel or source is good
For becoming a good Data Analyst , these are the steps you need to follow-
1) Understand Business - how they work , how data is important for them , which type of data can increase their revenue.
2) Learn Relevant Skills & tools - excell , SQL , Power BI or tabelue , also research for tools which are in demand these days and learn them too.
3) Profile Building - Make real time projects , take data from websites like kaggle , also take data from some real business and try to implement them , make dashboard ....make advance projects , see the people already in this industry , what projects are they making.... make ATS Friendly resume , do internship or freelancing projects
4) Build Network & Apply for Job - Use Platforms like Linked In , Twitter ...showcase your skills their and tag recruiters from your dream company....if your work will be good they will definitely reach back to you. At last apply for 100s of jobs , you will get reply from atleast 4-5 of them.
but sir why group by
Because we have duplicate machine id
Excellent Bhai 😍
Glad it was helpful to you....If you really liked the content, do share with your friends too 😄 💯
Hi @learnwithchirag how did you able to run the code to get output int grid format at 5:30
thanks bhayia
Always welcome. Keep watching 🎉
please explain how ON is working here!!!!!
The "ON" clause in this query specifies the conditions for joining records from the Activity table with itself (a1 and a2 instances) based on matching process_id and machine_id, and ensuring that the activities are ordered correctly in terms of time.
If its still not clear , I will request you to dry run the query once. And no need to worry , you will get the clarity of concept when you will complete the playlist.
Start from video 1 and go till video 50. You will be a champ in SQL.💯
😢@@learnwithchirag
Nice Explaination!
Thanks! Keep Watching 🎉
why we created a1 and a2
It's called self join. We created two instances of a single table in order to return the required result.
Please do watch all the videos you will get this concept more clearly! Keep Learning 💯