SQL "difference between" interview questions (part 1)

Поділитися
Вставка
  • Опубліковано 5 вер 2024

КОМЕНТАРІ • 266

  • @madhurpalsokar7790
    @madhurpalsokar7790 4 роки тому +25

    Best thing about your videos is You take very less time to cover many things and yet explaining it so beautifully.. Thanks for spreading the knowledge.. 👍🏻

  • @nagoredeen
    @nagoredeen 3 роки тому +47

    You can still use WHERE clause aggregated functions.
    Select max(column) from table where
    Meaning: select max out of a column value from a table with a filtered records based on a condition.

  • @chandrassqlbi4343
    @chandrassqlbi4343 4 роки тому +126

    Great job sis.. kudos!!
    Small correction @ 3:33 ---- 'Where' can be used while aggregating rows (Where and Group by works)
    'Where' will filter at Row level
    'Having' will filter at 'Group by' level
    No intention of pointing out mistakes here.. your channel is gaining popularity, and many are learning from this channel, great job!!. On the same lines - my two cents .. if that helps your viewers!!
    Oh, I haven't seen before - couple of others also mentioned about this correction.. great!! Good job!!
    (wouldn't have posted this if i have seen that earlier)
    Good job everyone!! Happy learning!!

    • @crackconcepts
      @crackconcepts  3 роки тому +10

      Thank you 😊

    • @antonyjayaraj95
      @antonyjayaraj95 3 роки тому +3

      I really like the way you explained and it is useful for me...

    • @praveengupta2369
      @praveengupta2369 3 роки тому +1

      Sir I need to add few more points and let me know if I am wrong. If where clause is being used after the 'group by' statement this wouldn't work out. If we want SQL to use group by with where, 'where clause' should be used before Group by statement which actually filters the data from reference table first then grouping the data. Since, we are not using any aggregate function to group our data hence this group by also acts like order by. Disagree if I am wrong

    • @rameshmalhotra9525
      @rameshmalhotra9525 2 роки тому

      ua-cam.com/video/p0gL1pAhGZE/v-deo.html

    • @vaishalidharmik2038
      @vaishalidharmik2038 Рік тому

      Thanks for this. I could have got wrong understanding now about using HAVING clause.

  • @crackconcepts
    @crackconcepts  3 роки тому +28

    Hi, please watch the below linked video to understand the difference between WHERE and HAVING even better.
    ua-cam.com/video/ggBXefD4UT8/v-deo.html
    ✨Link to my SQL e-book: imojo.in/rkajq9
    ✨Link to 'Switch your career easily' e-book: imojo.in/1FL7KaG
    (Perfect for anyone willing to switch to a completely new field or to a different company in the Tech World)

    • @bhuvananithu1466
      @bhuvananithu1466 2 роки тому

      . mn

    • @ramireddygopalreddy4316
      @ramireddygopalreddy4316 2 роки тому

      how to contact u mam

    • @afuhcyrilcheuck5032
      @afuhcyrilcheuck5032 2 роки тому

      I need help , the other video you made explaining how you to find the second highest salary with MAX . It was
      Select MAX(salary) from employee
      Where salary < ( select Max
      (Salary) from employee ). Thats using an aggregated function with "where "which you just said otherwise

    • @balanagadurgasrilakshmi8562
      @balanagadurgasrilakshmi8562 2 роки тому

      Hii I want to
      Take course from you how can I contact you pls

    • @sumityerme3811
      @sumityerme3811 2 роки тому +1

      Thanku mam

  • @narenderuggera1972
    @narenderuggera1972 3 роки тому +86

    I became fan of your voice nd thanks for the most common interview question explained in great manner👍👍👍🙏

  • @radhemohannaamhai
    @radhemohannaamhai 3 роки тому +5

    The way she says sorry sorry ❤️.. great tutorial ..am following every video.. simple and to the point ..

  • @kunalgandhe4551
    @kunalgandhe4551 Рік тому +1

    I've been looking for something like this from a long time.I've not seen any video where SQL is explained in such a simple and easy way. Thanks a lot for this.

  • @nishanthgaddam8426
    @nishanthgaddam8426 4 роки тому +5

    We can use where clause and having too because we can filter non aggregated value and having count(emp_id)>=1 . Instead of using having emp_id>105 u shld have use where emp_id>105

    • @crackconcepts
      @crackconcepts  4 роки тому +1

      Correct. Made a mistake there. Thanks for correcting! :)

    • @nishanthgaddam8426
      @nishanthgaddam8426 4 роки тому

      @@crackconcepts No worries and thank you for educating us 😀😊

  • @anvi015
    @anvi015 8 місяців тому +1

    Amazing video series on SQL. Honestly this has been my ONLY goto channel whenever I feel I need to brush up my SQL coding skills.

  • @dipakk123
    @dipakk123 3 роки тому +3

    I am thankful that such a clear and knowledgeful information shared for all
    May God bless you for the helping and sharing
    thank you

  • @sohailkat8867
    @sohailkat8867 4 роки тому +5

    I have started watching your videos recently, believe me you are amazing the way explained just nailed it.Impressive work keep it up last but not least thank you.

  • @hadireg
    @hadireg 2 роки тому +2

    Having is the only solution giving you the option to filter on the results of the aggregate function. Where can still be used on the other fields of the dataset before the aggregate functions are processed.

  • @charlesmathews6184
    @charlesmathews6184 3 роки тому +6

    I gained confidence from your teaching. Kudos

  • @suhailahamed7514
    @suhailahamed7514 3 роки тому +3

    Thank you, sister, the way you teach is wonderful, stay blessed and happy forever. as a beginner, I admire your effort.

  • @AMITVISHWAKARMA-dy2wi
    @AMITVISHWAKARMA-dy2wi 3 роки тому +27

    When we use max() function still we can use the where clause it works.

  • @vminkook_lover782
    @vminkook_lover782 3 роки тому +21

    Whatt a Amazing voice !!!😍😍🥰♥️
    & Explanation is also good 💜

  • @deepakpandey9406
    @deepakpandey9406 3 роки тому

    1. Aggregate
    2. Duplicate
    3. Scan and Boolean evaluation
    4. Position
    5. Performance
    6. Columns and Rows

  • @itdp.warangal
    @itdp.warangal 2 роки тому

    I think this video was done at election time. This video helped me now. Nyc1

  • @shreyjainhere
    @shreyjainhere 3 роки тому +2

    Your voice is really sweet Mam.. A very good and simple way of explaining 👍

  • @adityaraizada7614
    @adityaraizada7614 3 роки тому +15

    Great job
    But one small correction at 3:57 where can be used also with group by but before group by statement and having can be used on aggregate function as you said
    Like:
    SELECT MAX(Sal) FROM Employee
    GROUP BY EmpId
    HAVING MAX(Sal) > 1000;

  • @vijayarahavanrajagopal6885
    @vijayarahavanrajagopal6885 Рік тому +1

    Aggregate function
    It is used to multiple rows of single column

  • @RahulGupta-fk4cz
    @RahulGupta-fk4cz 6 місяців тому

    Mam your voice is so sweet and the way of your teaching is also good

  • @sartz444
    @sartz444 3 роки тому +1

    Hi, The best thing is that All of your videos are clearly explained in a short period of Time and it covers many things. I Really appreciate ur effort and please keep on continuing it🙏🙏 Thanks you so much

  • @anilb5557
    @anilb5557 2 роки тому

    thank u mam such simple explaination about union i never understand my whole enginnering .....keep provide us such .. this type of information... thank u so mmuch ......🤗🤗🤗🤗🤗🤗🤗

  • @rohanmali6583
    @rohanmali6583 3 роки тому +4

    This and the second part is sooooo Awesome. You Rock. Blessings from United States. :)

  • @iiampra
    @iiampra 3 роки тому +14

    what a voice WOW

  • @bootexcel5122
    @bootexcel5122 2 роки тому

    Nice. You are explaining things clear. Like inner query and outer query.

  • @anunutan9220
    @anunutan9220 3 роки тому

    Ur way of explaining concepts is simple and cool to understand soon....
    Tq for sharing videos..

  • @tekieogubagabir43
    @tekieogubagabir43 4 роки тому +1

    clear, simple and easy way of explanation , Thank you !

  • @suhailsavo9291
    @suhailsavo9291 Місяць тому

    Execution order of clauses---
    1.From
    2.Where
    3.Group By
    4.Having
    5.Order by
    6.Select.

  • @JinkaJayakrishna
    @JinkaJayakrishna 4 місяці тому

    Mam the way of explanation is super thanks for given valuable classes

  • @archanapbhat5232
    @archanapbhat5232 3 роки тому

    Thank you..Concepts clearly explained in short time..GOD bless you

  • @tariqzaman2077
    @tariqzaman2077 2 роки тому

    A good and knowledgeable video, thank you sister for sharing with us.

  • @rakeshgopidi4066
    @rakeshgopidi4066 2 роки тому +2

    It's a great post @Crack Concepts (Sadia) , no matter how many years of experience we have ,it's always a good revision for any one
    # WHERE
    can be used with SELECT,INSERT,UPDATE statement
    # HAVING
    can only be used with SELECT statement

  • @vijayg1627
    @vijayg1627 2 місяці тому +1

    We can get the aggregate by using where as well

  • @chaithanyagosangi8950
    @chaithanyagosangi8950 3 роки тому +3

    mam, please note the correction that, where can be used in your explanation for id, having is only used for aggregated filters.

  • @gauravnegi4312
    @gauravnegi4312 3 роки тому

    THANK YOU SO MUCH!!!! Cleared all the doubts in a single go!

  • @unknowns9500
    @unknowns9500 2 роки тому

    we can use where instead of having , we use having when we place the group by clause

  • @abhishekpandey4660
    @abhishekpandey4660 4 роки тому +2

    Short,simple and clear explanation.. Really liked it so much:)

  • @nelikantinagaraj4866
    @nelikantinagaraj4866 2 роки тому

    Very very nice and simple methods with examples 😄😄😄 thank u for videos

  • @vijaypanchal7344
    @vijaypanchal7344 Рік тому

    Nice tutorial and clear voice to understand.

  • @avtarchandra2407
    @avtarchandra2407 4 роки тому +5

    That multiippllee rows❣️2:10

  • @Jooockerx
    @Jooockerx 2 роки тому

    Nice and clear explanation, thank you very much from south yemen.

  • @vS-mn9id
    @vS-mn9id 3 роки тому

    God bless... very straight to the point... Perfect... Kudos to your work

  • @CoolGuy
    @CoolGuy 2 роки тому +2

    Though I am using SQL(DBA) for 3 years, never focused much on the difference between UNION and UNION ALL. Today I gave an interview for one of the Big4 and I couldn't answer the difference between UNION vs UNION ALL. Finally landed here to understand the diff.

    • @trevorb9800
      @trevorb9800 2 роки тому

      ...... hopefully you don't use it because that's a massive difference LOL. You would ruin a dataset not using Union all. Union all is used 99.9% of the time. There would be no point to be removing duplicate rows.

    • @enlightenmentofsoul9650
      @enlightenmentofsoul9650 2 роки тому

      I think u just time pass if u don't know the difference sorry but it's true

  • @suyash7450
    @suyash7450 Рік тому

    When to use IN and exists this I learned from your video

  • @anujlovetube
    @anujlovetube 3 роки тому

    Best sql channel ...thanks mam for this series and all effort u have put in

  • @PrashantKumar-gc2pg
    @PrashantKumar-gc2pg 2 роки тому

    SELECT count(country) from customers where customerid>5;
    it is working

  • @vivamedia5958
    @vivamedia5958 4 роки тому +1

    Great tutorials. Thank You very much. looking forward for more videos from you.

  • @user-cr9yw9yg5v
    @user-cr9yw9yg5v Місяць тому

    Please explain the difference between partition by and group by

  • @SameerShaikh-ty5zt
    @SameerShaikh-ty5zt 2 роки тому

    Thank you.. Your way of explaining is sweet.

  • @yokeshviswanathan1220
    @yokeshviswanathan1220 3 роки тому

    amazing what a voice and you are explanation also awesome keep going

  • @prashantp9029
    @prashantp9029 2 роки тому +1

    Good job mam👍👍
    Please upload more videos regarding plsql with examples as many as u can .
    Your explanation is tremendous ...

  • @varunwadekar7
    @varunwadekar7 6 місяців тому

    very helpful for the interview preparation

  • @Faisal1504
    @Faisal1504 3 роки тому

    Thanks for sharing very well explained

  • @331sairam
    @331sairam 3 роки тому

    Straight concept clear voice ....cool

  • @gauravrawat5521
    @gauravrawat5521 2 роки тому

    Your notes are so well define easy to understand

  • @virendrabhati6685
    @virendrabhati6685 2 роки тому

    It was a great video of explaining such a complicated concepts 👍.

  • @ajinkya820
    @ajinkya820 3 роки тому +2

    You have a wonderful soft voice ..

  • @bhushandatey5792
    @bhushandatey5792 3 роки тому

    very well explained . I watched just one video & subscribed .

  • @danyos777
    @danyos777 3 роки тому +1

    I like the way you explain; your voice is clear and explanations are concise. I would have like to see a query written per each example/case to illustrate each use per clause.
    First time on your channel and looking forward to more of your SQL videos. BTY, I’m new to SQL, hoping to learn it fast, mastering this skill type of structure language.

  • @gauravghosh8002
    @gauravghosh8002 3 роки тому

    Thank you so much Ma'am for your detailed information. This helped me to brushed up

  • @SanjaySharma-rl3xu
    @SanjaySharma-rl3xu 2 роки тому +1

    This is nice!

  • @manognakarimi
    @manognakarimi 3 роки тому +2

    To the point ,
    helped me.
    Thank you 😀

  • @mukulverma9966
    @mukulverma9966 3 роки тому

    You are explaining so good and your voice also amazing
    Great work mam

  • @Rohitkumar-vq1yk
    @Rohitkumar-vq1yk Рік тому

    Thank you this has helped me a lot

  • @ashutoshgaur8105
    @ashutoshgaur8105 2 роки тому

    very nice voice, explained in good way

  • @yasmeenhasan9925
    @yasmeenhasan9925 2 роки тому

    Thanks for the making videos! Its very very helpful

  • @leadprogrammer
    @leadprogrammer 3 роки тому +5

    You do great efforts, aggregating those neatly written paper docs. It would require lot of hard work.
    Please give a try to ms word where changes or corrections also would be easier for you.
    And Mysql database with ms workbench which is opensource, would save your time and your efforts a lot.
    Great work, you would come up with flying colours. Best of luck...

  • @ramanv3744
    @ramanv3744 4 роки тому +1

    Highly appreciate your work. Thanks

    • @prajaktashah7011
      @prajaktashah7011 4 роки тому +1

      @@Rajahmundry-timepass I ran all queries and they are working fine. If you can't run simple queries, stop blaming the teacher. You piece of shit.
      Stop spreading negativity for her. She is doing a great job. But stupid people like you can't understand anything.

  • @TheTiwari331
    @TheTiwari331 3 роки тому

    Please make more difference between in Location and Add...

  • @abhidobhal8885
    @abhidobhal8885 3 роки тому +3

    You are doing well, Great job but your voice was awesome than topic.

  • @parthasarathyraja8917
    @parthasarathyraja8917 3 роки тому

    Volume of teaching can be increased to hear well and understand.Thank you

  • @deepakkumaar9665
    @deepakkumaar9665 4 роки тому +2

    Voice is pleasant

  • @SureshKumar-ug4ep
    @SureshKumar-ug4ep 3 роки тому

    Very nicely explained! and your voice is soooo sweet!
    Keep it up👍

  • @Kamil0289
    @Kamil0289 2 роки тому

    Simply explained, thank you :)

  • @sivareddyalavala4425
    @sivareddyalavala4425 2 роки тому

    Good explanation

  • @akashjariwala5354
    @akashjariwala5354 3 роки тому

    Thank you ma'am. Cause of you i was able to crack the interview for my dream job ❤

    • @crackconcepts
      @crackconcepts  3 роки тому +1

      I’m so happy for you. Congratulations!

    • @akashjariwala5354
      @akashjariwala5354 3 роки тому

      @@crackconcepts thank you. Andbi am very much greatful to your videos. I learned more from your course then in 6 mths of my college

  • @naveen4481
    @naveen4481 3 роки тому

    also add one more component --group by and partition by

  • @shreyas_jay
    @shreyas_jay Рік тому

    Thanks for this video ...

  • @user-pe9wc7ig2i
    @user-pe9wc7ig2i 3 роки тому

    Great explanation, thank you, dear

  • @ajajjamadar
    @ajajjamadar 3 роки тому

    Great job sister . Best tutorials I have ever seen . Keep it up

  • @niranjanbhosale5101
    @niranjanbhosale5101 3 роки тому

    The concept explained is correct but the example given is wrong for where Vs having. WHERE doesn't work with aggregate functions when they are mentioned directly in WHERE clause. For ex:- SELECT count(empid) from employee where salary>avg(salary). This would give an error. But your query where you are using aggregate in select but not in where it would work just fine. Hope you understand it ✌️

  • @poojatiwari6290
    @poojatiwari6290 2 роки тому

    Nice way of explaining 👍

  • @mushiburrahamanmallick3372
    @mushiburrahamanmallick3372 2 роки тому

    excellent

  • @anshikakhandelwal1348
    @anshikakhandelwal1348 3 роки тому +1

    select max(sal) from emp
    having empno>7900
    Will given an error ORA-00979: not a Group BY expression
    having keyword cannot be used without group by

    • @manpreetsrmcem
      @manpreetsrmcem 3 роки тому

      Please use where in place of having. Having is used with agreegate condition and with group by is also require. In video everything is not correct..

  • @sutharshansrikumar3001
    @sutharshansrikumar3001 2 роки тому

    Very nice explanation

  • @sonukumar-pr2nc
    @sonukumar-pr2nc 5 років тому +1

    achha pdhati ho, keep it .

  • @netwkeng7101
    @netwkeng7101 3 роки тому

    You are doing great job sister with husky voice

  • @kumarakrish3976
    @kumarakrish3976 3 роки тому

    Proper explanation with great presentation 😊

  • @bollywoodupdates1706
    @bollywoodupdates1706 2 роки тому

    Thank you for the video!

  • @vipin2872
    @vipin2872 2 роки тому

    Nicely explained. Mam

  • @manikantatatvamasi7804
    @manikantatatvamasi7804 3 роки тому

    NIcely explained, Thank you

  • @letsdoit6438
    @letsdoit6438 2 роки тому

    Excellent explanation

  • @prakashvish3988
    @prakashvish3988 3 роки тому +2

    Very mild n cute voice ❤️

  • @Lalit_Sharma_20
    @Lalit_Sharma_20 2 роки тому

    soothing voice and excellent explanation !! too good. Can we get these notes ?

  • @tanushreenagar3116
    @tanushreenagar3116 2 роки тому

    Nice mam 👍 thanks 😊

  • @ShubhamKumar-fz3oc
    @ShubhamKumar-fz3oc 3 роки тому

    One suggestion please add the final output also..it will really help many

  • @jvinaykumar3274
    @jvinaykumar3274 2 роки тому

    Awesome voice and good explanation 😍

  • @buildtolearn
    @buildtolearn Рік тому

    Love these videos. Great job!