SQL Tutorial | How to Avoid a Divide By Zero Error in SQL | NULLIF

Поделиться
HTML-код
  • Опубликовано: 15 май 2023
  • In this SQL tutorial, we learn some techniques to avoid the Divide By Zero error in SQL.
    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...
    Must Do Data Analytics Certifications -
    Google Data Analytics Professional Certificate
    imp.i384100.net/OR37oQ
    Google Advanced Data Analytics Professional Certificate
    imp.i384100.net/eK1WmQ
    Best Data Science / Analytics / SQL courses
    Learn SQL Basics for Data Science Specialization
    imp.i384100.net/qnXYk5
    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/
    Instagram - / learn.knowstar
    Blog - know-star.blogspot.com/
    Facebook - / knowstartrainings
    Linkedin - www.linkedin.com/company/know...
    Email - learn@knowstar.org

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

  • @babytigtig3795
    @babytigtig3795 2 месяца назад

    Thanks I really need this help with sql server

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

    Thank you for posting this video. Though it sounds simple, it is of great use for many folks.Keep posting the tricky SQL videos.

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

    Thanks, helpful!

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

    I use case statement in that condition

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

    Select Date_reported, SUM(New_cases) as Totalcases,SUM(cast(New_deaths as int)) as TotalDeaths ,
    SUM(cast(New_deaths as int))/NULLIF (SUM(New_cases,0),0)*100 as TotalPercentage
    From portfolioproject.. ['WHO-COVID-19-global-data$']
    Group by Date_reported Can you please help me about this i got an error it says the sum functions requires 1 argument.

    • @OazadOMER
      @OazadOMER 11 месяцев назад

      If I'm not wrong you need to delete last ,0) => NULLIF (SUM(New_cases,0)*100