SQL tutorial | Date Functions | Difference between DATEDIFF and DATEADD

Поделиться
HTML-код
  • Опубликовано: 9 июл 2024
  • In this video, we learn about some of the most important date functions in SQL Server -
    Getdate()
    Datediff
    Dateadd
    Datepart
    Datename
    Eomonth
    Examples of implementations for Date Functions -
    1) Find number of weekdays between two dates - Exclude Weekends
    • SQL Query | Calculate ...
    2) Find age from Birthdate
    • SQL Tutorial | Date Fu...
    3) Calculate biweekly Friday dates
    • SQL Query | How to cal...
    4) Find first and last day of week - method 1
    • SQL Query | How to fin...
    5) Find first and last day of week - method 2
    • SQL Query | Date Funct...
    6) How to find number of Sundays between two dates
    • SQL | How to find numb...
    7) How to find number of Sundays in a month
    • SQL | Count number of ...
    8) Convert date to full ordinal long format
    • SQL | Convert date for...
    9) Update only year part of the date to a constant value
    • SQL | Update Year part...
    How to install SQL Server for practice?
    • How to install SQL Ser...
    Check out the complete list of SQL Query Interview Questions -
    • SQL Query Interview Qu...
    Best Data Science / Analytics / SQL courses
    Learn SQL Basics for Data Science Specialization
    imp.i384100.net/qnXYk5
    Beginners to Python Programming
    skillshare.eqcm.net/GjMakm
    Data Science and Business Analytics with Python
    skillshare.eqcm.net/JrM1Aq
    IBM Data Science Professional Certificate
    imp.i384100.net/LPQvg3
    Data Science Fundamentals with Python and SQL Specialization
    imp.i384100.net/mgVYre
    Python for Everybody Specialization
    imp.i384100.net/DVz7Aj
    Google Data Analytics Professional Certificate
    imp.i384100.net/OR37oQ
    Coursera Plus - Data Science Career Skills
    imp.i384100.net/c/3299742/132...
    Please do not forget to like, subscribe and share.
    For enrolling and enquiries, please contact us at
    Website - knowstar.org/
    Facebook - / knowstartrainings
    Instagram - / learn.knowstar
    Linkedin - www.linkedin.com/company/know...
    Email - learn@knowstar.org

Комментарии • 19

  • @LearnatKnowstar
    @LearnatKnowstar  Год назад +6

    Here are the examples for practicing these Date functions -
    1) Find number of weekdays between two dates - Exclude Weekends
    ruclips.net/video/tzfRdzgt1JM/видео.html
    2) Find age from Birthdate
    ruclips.net/video/VqSD35pY9e4/видео.html
    3) Calculate biweekly Friday dates
    ruclips.net/video/Y-Bk_gWqEqM/видео.html
    4) Find first and last day of week - method 1
    ruclips.net/video/lXcaqzx2v90/видео.html
    5) Find first and last day of week - method 2
    ruclips.net/video/0elDBuPGd6M/видео.html
    6) How to find number of Sundays between two dates
    ruclips.net/video/fGAuoRkaky0/видео.html
    7) How to find number of Sundays in a month
    ruclips.net/user/shorts0JoZjO337tA
    8) Convert date to full ordinal long format
    ruclips.net/user/shortsJtpLMxkp6kE
    9) Update only year part of the date to a constant value
    ruclips.net/user/shortscFtJdvUx_ZM

  • @Magswap
    @Magswap 11 месяцев назад +1

    It's crazy how much value your videos give, the explanations, and just each topic you do is so unique to everyone else on YT. Very well done 👏

  • @designanddecor8964
    @designanddecor8964 Год назад +2

    Very helpful. Please keep posting.

  • @Freakouts_and_found_Insane
    @Freakouts_and_found_Insane Год назад +2

    Thanks for sharing ...your all videos arel very informative 🙏

  • @AnshulMarele-gbaa
    @AnshulMarele-gbaa Год назад +1

    Hi, as you are typing the function name like GetDate(), you are getting the function syntax. How to enable it in SSMS?

  • @aanchalsrivastava8550
    @aanchalsrivastava8550 Год назад +1

    Can u explain nested replace with example.

  • @deepaliveer28
    @deepaliveer28 Год назад

    Hello, There is one date column. I want to apply filter for that column. It would show the records of lask week dates only. How to do that. Any suggestions?

  • @sireeshagiddaluru4186
    @sireeshagiddaluru4186 10 месяцев назад

    How to get null values when we use datediff function?

  • @hv0032113
    @hv0032113 Год назад

    Thank you for the clear explanation.

  • @AlwaysBeTactful
    @AlwaysBeTactful 7 месяцев назад

    Please what can i do when i get this message "'DATE_PART' is not a recognized built-in function name."

  • @ramadevigarnepudi-xh8iu
    @ramadevigarnepudi-xh8iu Год назад

    Hi madam I want SQL resume pls two yeras

  • @shivaramkrishnameduri8012
    @shivaramkrishnameduri8012 Год назад

    Thanks for making the video. Can you help me in how to get age in the firm of 30 years, 8 months, 13 days in sql. From the date of birth column. This is asked me in the previous interview

    • @LearnatKnowstar
      @LearnatKnowstar  Год назад

      This is a very good question. Will post the answer for everyone soon! Please keep sharing these wonderful questions!

  • @nikolaybaranov2213
    @nikolaybaranov2213 Год назад

    I have a very stupid question: why difference in weeks between Saturday and Sunday equal 1? Week starts on Monday, Saturday and Sunday refer to the same week of the year.
    SQL Query:
    SELECT DATEDIFF (week, '2023-05-27', '2023-05-28')
    ,DatePart (week, '2023-05-28')
    ,DatePart (week, '2023-05-27')
    ,@@DATEFIRST

    Result:
    1 22 22 1