SQL Questions For Practice

  1. Given the following table called “employees”, write a SQL query to select all employees who have a salary greater than 50,000:

    Capture

  2. Given the following table called “orders”, write a SQL query to select the total number of orders for each product:

    Capture

  3. Given the following tables called “students” and “courses”, write a SQL query to select all students who are enrolled in the “Math” course:

    Capture

1 Like

@kalyani-ta-ds

  1. select * from employees where salary >50000
  2. select count(*) from orders
  3. select Name from students S join
    courses C on S.id = C.id where C.course_name = “Math”
2 Likes

Great @sriv.ansh :grin:, thank you for participating!

Very Good keep Practicing @sriv.ansh

1 Like