LAB 5.docx - LAB#5 1 Write an SQL statement that displays the training names and training costs for courses that cost between 1000 and 1200(inclusive

LAB 5.docx - LAB#5 1 Write an SQL statement that displays...

This preview shows page 1 - 2 out of 4 pages.

LAB #5 1. Write an SQL statement that displays the training names and training costs for courses that cost between 1000 and 1200 (inclusive). Don’t use the BETWEEN Clause. a. SELECT TrainingName, TrainingCost FROM TrainingCourse WHERE TrainingCost >= 1000 or TrainingCost <= 1200; 2. Using the BETWEEN clause, write an SQL statement that displays the training names and training costs for courses that cost between 1000 and 1200 (inclusive). Order the output by training cost from highest to lowest. a. SELECT TrainingName, TrainingCost FROM TrainingCourse WHERE TrainingCost BETWEEN (1000) AND (1200) ORDER BY TrainingCost DESC; 3. Write an SQL statement that displays training IDs and training names for all courses that contain the word ‘customer’ in the training description. Order the output by training name from A-Z. a. SELECT TrainingID, TrainingName FROM TrainingCourse WHERE TrainingDescription LIKE ‘%customer%’ ORDER BY TrainingName ; 4. Write an SQL statement that shows any Null values for States in the CUSTOMER Table. a. SELECT * FROM Customer WHERE State IS null; 5. Write an SQL statement to count the number of customers in the CUSTOMER Table. Include an Aliases when appropriate. a. SELECT COUNT(CustomerID) as ‘NumberOfCustomers’ FROM Customer; 6. Write an SQL statement that counts the number of customers from Texas. Include an Aliases when appropriate.
Image of page 1

Subscribe to view the full document.

Image of page 2
  • Fall '13
  • RobertMills

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern

Ask Expert Tutors You can ask You can ask ( soon) You can ask (will expire )
Answers in as fast as 15 minutes