SlideShare a Scribd company logo
‘Repairs’ Questions
The ‘Repairs’ database is for a computer repair store. It has four tables:
Devices (type, rate, priority)
Technicians (Id, name, grade)
Experience (Id, type, qualification)
Repair (Job, Id, type, owner, date, time, ready, cost)
Look in the Devices table and view the different types of repairs (MM stands
for Multimedia device, DD means disk drive). Each type of device has a repair
rate per ¼ hour spent on it, and a priority level of either low (L), medium (M),
or high (H).
The Technicians table lists the employees and their skill level.
The Experience table shows each technicians ability to repair different
devices (Novice (N) or Experienced (E)).
The Repair table gives each repair a unique job number, as well as other
required data.
Create and save SQL queries for the following:
1. Show the name and grade of all technicians
2. Show everything about all devices.
3. Show the different rates that are charged, from lowest to highest (no
duplicates).
4. Show all of the jobs (and the type) being worked on by technician
1470.
5. For all multimedia repairs, show the owner and the date of the job.
6. Show all of the jobs that have been around since before the 4th of June.
7. Show the different type of repairs that technician 1470 is working on
(no duplicates).
8. Show the different types of devices repaired and the rate charged for
each.
9. What is the name of the technician with the ID 1310?
10. Which devices are charged at a rate of $30 per ¼ hour?
11. List the identity numbers of technicians who have expert qualifications.
12. Which devices are ready for collection?
13. What is the level of experience of technician 1470 when working on
iMacs?
14. Find the jobs being worked on by technicians 1470 and 1011.
15. The order of ANDs and ORs can affect the result. ANDs are always
worked out first. To make sure you get the result you expect, always
use brackets. For example, type the following two queries in and see
what difference the brackets make:
SELECT job, id, type
FROM repair
WHERE id=1470 OR id=1008
AND type=’iMac’ OR type=’MM’

SELECT job, id, type
FROM repair
WHERE (id=1470 OR id=1008)
AND (type=’iMac’ OR type=’MM’)

16. Show type, rate and priority of devices that have a rate of $20 or $25,
and are also either a multimedia device or a disk drive.
17. Show the owners and job dates of all repairs between June 4th and
June 6th.
18. Use the In operator to show the rates for input and output devices.

19. Show all of the owners with names beginning with ‘B’.
20. Show any five-letter technician names starting with ‘C’.
21. Show the number of hard drives being repaired.
22. Show the maximum time taken to repair each device type.
23. Edit the previous query to display the maximum time with the heading
“Maximum Time” and with the text “quarter hours” appended to the
values (e.g. ‘4 quarter hours’).
24. What is the average time each technician takes to complete a job?
25. Show the number of jobs entered on each date.
26. Show the type of devices that have exactly two jobs.
27. List the jobs that have a high priority.
28. Show the ID and name of technicians who are classed as experts.
29. Which high priority devices being worked on by Johnson are ready for
collection?
30. What is the date entered for all low priority repairs?
31. Show the device type and repair rate for devices that have technicians
who are novices.
32. Which technicians are experts at repairing iMacs?
33. What is the grade of the technician repairing the device owned by
James?
34. What will be the charge for the repair to Elliot’s device?
35. Who owns devices being repaired by Ted Carrol?
36. What are the names of the technicians who are still not expert (N) at
repairing Macs?
37. What rate will Byrne be charged for repairs?
38. List the owners whose devices have a high priority for repair.
39. What level of qualification has the technician who is doing Taylor’s
repair job?

More Related Content

Similar to Repairs questions

Traing and aquired skills
Traing and aquired skillsTraing and aquired skills
Traing and aquired skillsRaymond Salinas
 
What is data center availability modes slide
What is data center availability modes slideWhat is data center availability modes slide
What is data center availability modes slideLivin Jose
 
Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...
Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...
Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...Alpro
 
Digital Electronics & Fundamental of Microprocessor-I
Digital Electronics & Fundamental of Microprocessor-IDigital Electronics & Fundamental of Microprocessor-I
Digital Electronics & Fundamental of Microprocessor-Ipravinwj
 
90 Informatics Practices.pdf
90 Informatics Practices.pdf90 Informatics Practices.pdf
90 Informatics Practices.pdfvikas500500
 
CIS 115 Exceptional Education - snaptutorial.com
CIS 115   Exceptional Education - snaptutorial.comCIS 115   Exceptional Education - snaptutorial.com
CIS 115 Exceptional Education - snaptutorial.comDavisMurphyB33
 
Introduction to Embedded Systems (1).pptx
Introduction to Embedded Systems (1).pptxIntroduction to Embedded Systems (1).pptx
Introduction to Embedded Systems (1).pptxpriyaanaparthy
 
Cis 115 Education Organization -- snaptutorial.com
Cis 115   Education Organization -- snaptutorial.comCis 115   Education Organization -- snaptutorial.com
Cis 115 Education Organization -- snaptutorial.comDavisMurphyB99
 
cs305-170108135047 (1).ppt
cs305-170108135047 (1).pptcs305-170108135047 (1).ppt
cs305-170108135047 (1).pptRajDhrub
 
Peripherals and Ports
Peripherals and PortsPeripherals and Ports
Peripherals and PortsBryan Corpuz
 
Cis 115 Education Organization / snaptutorial.com
Cis 115 Education Organization / snaptutorial.comCis 115 Education Organization / snaptutorial.com
Cis 115 Education Organization / snaptutorial.comBaileya126
 

Similar to Repairs questions (20)

Traing and aquired skills
Traing and aquired skillsTraing and aquired skills
Traing and aquired skills
 
S M UMER WASI
S M UMER WASIS M UMER WASI
S M UMER WASI
 
Training report_orginal
Training report_orginalTraining report_orginal
Training report_orginal
 
Bhagyesh's IR TECH
Bhagyesh's IR TECHBhagyesh's IR TECH
Bhagyesh's IR TECH
 
What is data center availability modes slide
What is data center availability modes slideWhat is data center availability modes slide
What is data center availability modes slide
 
Final Report
Final ReportFinal Report
Final Report
 
Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...
Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...
Computer paper 3 may june 2004 9691 cambridge General Certificate of educatio...
 
ALLEN HEINRICHS RESUME
ALLEN HEINRICHS RESUME ALLEN HEINRICHS RESUME
ALLEN HEINRICHS RESUME
 
Digital Electronics & Fundamental of Microprocessor-I
Digital Electronics & Fundamental of Microprocessor-IDigital Electronics & Fundamental of Microprocessor-I
Digital Electronics & Fundamental of Microprocessor-I
 
90 Informatics Practices.pdf
90 Informatics Practices.pdf90 Informatics Practices.pdf
90 Informatics Practices.pdf
 
S m umer wasi
S m umer wasiS m umer wasi
S m umer wasi
 
CIS 115 Exceptional Education - snaptutorial.com
CIS 115   Exceptional Education - snaptutorial.comCIS 115   Exceptional Education - snaptutorial.com
CIS 115 Exceptional Education - snaptutorial.com
 
Original assignment
Original assignmentOriginal assignment
Original assignment
 
Introduction to Embedded Systems (1).pptx
Introduction to Embedded Systems (1).pptxIntroduction to Embedded Systems (1).pptx
Introduction to Embedded Systems (1).pptx
 
06
0606
06
 
CMMS - From Theory to Execution
CMMS - From Theory to ExecutionCMMS - From Theory to Execution
CMMS - From Theory to Execution
 
Cis 115 Education Organization -- snaptutorial.com
Cis 115   Education Organization -- snaptutorial.comCis 115   Education Organization -- snaptutorial.com
Cis 115 Education Organization -- snaptutorial.com
 
cs305-170108135047 (1).ppt
cs305-170108135047 (1).pptcs305-170108135047 (1).ppt
cs305-170108135047 (1).ppt
 
Peripherals and Ports
Peripherals and PortsPeripherals and Ports
Peripherals and Ports
 
Cis 115 Education Organization / snaptutorial.com
Cis 115 Education Organization / snaptutorial.comCis 115 Education Organization / snaptutorial.com
Cis 115 Education Organization / snaptutorial.com
 

More from hccit

Snr ipt 10_syll
Snr ipt 10_syllSnr ipt 10_syll
Snr ipt 10_syllhccit
 
Snr ipt 10_guide
Snr ipt 10_guideSnr ipt 10_guide
Snr ipt 10_guidehccit
 
3 d modelling_task_sheet_2014_yr12
3 d modelling_task_sheet_2014_yr123 d modelling_task_sheet_2014_yr12
3 d modelling_task_sheet_2014_yr12hccit
 
3 d modelling_task_sheet_2014_yr11
3 d modelling_task_sheet_2014_yr113 d modelling_task_sheet_2014_yr11
3 d modelling_task_sheet_2014_yr11hccit
 
10 ict photoshop_proj_2014
10 ict photoshop_proj_201410 ict photoshop_proj_2014
10 ict photoshop_proj_2014hccit
 
Photoshop
PhotoshopPhotoshop
Photoshophccit
 
Flash
FlashFlash
Flashhccit
 
University partnerships programs email
University partnerships programs emailUniversity partnerships programs email
University partnerships programs emailhccit
 
Griffith sciences pathway programs overview
Griffith sciences pathway programs overviewGriffith sciences pathway programs overview
Griffith sciences pathway programs overviewhccit
 
Griffith info tech brochure
Griffith info tech brochureGriffith info tech brochure
Griffith info tech brochurehccit
 
Pm sql exercises
Pm sql exercisesPm sql exercises
Pm sql exerciseshccit
 
Movies questions
Movies questionsMovies questions
Movies questionshccit
 
Australian birds questions
Australian birds questionsAustralian birds questions
Australian birds questionshccit
 
Section b
Section bSection b
Section bhccit
 
Section a
Section aSection a
Section ahccit
 
Ask manual rev5
Ask manual rev5Ask manual rev5
Ask manual rev5hccit
 
Case study report mj
Case study report mjCase study report mj
Case study report mjhccit
 
Mj example case_study_layout_intro_completedq
Mj example case_study_layout_intro_completedqMj example case_study_layout_intro_completedq
Mj example case_study_layout_intro_completedqhccit
 

More from hccit (20)

Snr ipt 10_syll
Snr ipt 10_syllSnr ipt 10_syll
Snr ipt 10_syll
 
Snr ipt 10_guide
Snr ipt 10_guideSnr ipt 10_guide
Snr ipt 10_guide
 
3 d modelling_task_sheet_2014_yr12
3 d modelling_task_sheet_2014_yr123 d modelling_task_sheet_2014_yr12
3 d modelling_task_sheet_2014_yr12
 
3 d modelling_task_sheet_2014_yr11
3 d modelling_task_sheet_2014_yr113 d modelling_task_sheet_2014_yr11
3 d modelling_task_sheet_2014_yr11
 
10 ict photoshop_proj_2014
10 ict photoshop_proj_201410 ict photoshop_proj_2014
10 ict photoshop_proj_2014
 
Photoshop
PhotoshopPhotoshop
Photoshop
 
Flash
FlashFlash
Flash
 
University partnerships programs email
University partnerships programs emailUniversity partnerships programs email
University partnerships programs email
 
Griffith sciences pathway programs overview
Griffith sciences pathway programs overviewGriffith sciences pathway programs overview
Griffith sciences pathway programs overview
 
Griffith info tech brochure
Griffith info tech brochureGriffith info tech brochure
Griffith info tech brochure
 
Pm sql exercises
Pm sql exercisesPm sql exercises
Pm sql exercises
 
Movies questions
Movies questionsMovies questions
Movies questions
 
Australian birds questions
Australian birds questionsAustralian birds questions
Australian birds questions
 
Section b
Section bSection b
Section b
 
B
BB
B
 
A
AA
A
 
Section a
Section aSection a
Section a
 
Ask manual rev5
Ask manual rev5Ask manual rev5
Ask manual rev5
 
Case study report mj
Case study report mjCase study report mj
Case study report mj
 
Mj example case_study_layout_intro_completedq
Mj example case_study_layout_intro_completedqMj example case_study_layout_intro_completedq
Mj example case_study_layout_intro_completedq
 

Recently uploaded

IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxAbida Shariff
 
Demystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyDemystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyJohn Staveley
 
Powerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaPowerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaCzechDreamin
 
WSO2CONMay2024OpenSourceConferenceDebrief.pptx
WSO2CONMay2024OpenSourceConferenceDebrief.pptxWSO2CONMay2024OpenSourceConferenceDebrief.pptx
WSO2CONMay2024OpenSourceConferenceDebrief.pptxJennifer Lim
 
Top 10 Symfony Development Companies 2024
Top 10 Symfony Development Companies 2024Top 10 Symfony Development Companies 2024
Top 10 Symfony Development Companies 2024TopCSSGallery
 
Speed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in MinutesSpeed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in Minutesconfluent
 
Designing for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastDesigning for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastUXDXConf
 
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...CzechDreamin
 
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdfIntroduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdfFIDO Alliance
 
Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024Enterprise Knowledge
 
Buy Epson EcoTank L3210 Colour Printer Online.pptx
Buy Epson EcoTank L3210 Colour Printer Online.pptxBuy Epson EcoTank L3210 Colour Printer Online.pptx
Buy Epson EcoTank L3210 Colour Printer Online.pptxEasyPrinterHelp
 
Buy Epson EcoTank L3210 Colour Printer Online.pdf
Buy Epson EcoTank L3210 Colour Printer Online.pdfBuy Epson EcoTank L3210 Colour Printer Online.pdf
Buy Epson EcoTank L3210 Colour Printer Online.pdfEasyPrinterHelp
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekCzechDreamin
 
Strategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering TeamsStrategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering TeamsUXDXConf
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...CzechDreamin
 
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FIDO Alliance
 
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfHow Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfFIDO Alliance
 
Connecting the Dots in Product Design at KAYAK
Connecting the Dots in Product Design at KAYAKConnecting the Dots in Product Design at KAYAK
Connecting the Dots in Product Design at KAYAKUXDXConf
 
Optimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through ObservabilityOptimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through ObservabilityScyllaDB
 
Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Patrick Viafore
 

Recently uploaded (20)

IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
 
Demystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John StaveleyDemystifying gRPC in .Net by John Staveley
Demystifying gRPC in .Net by John Staveley
 
Powerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara LaskowskaPowerful Start- the Key to Project Success, Barbara Laskowska
Powerful Start- the Key to Project Success, Barbara Laskowska
 
WSO2CONMay2024OpenSourceConferenceDebrief.pptx
WSO2CONMay2024OpenSourceConferenceDebrief.pptxWSO2CONMay2024OpenSourceConferenceDebrief.pptx
WSO2CONMay2024OpenSourceConferenceDebrief.pptx
 
Top 10 Symfony Development Companies 2024
Top 10 Symfony Development Companies 2024Top 10 Symfony Development Companies 2024
Top 10 Symfony Development Companies 2024
 
Speed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in MinutesSpeed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in Minutes
 
Designing for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at ComcastDesigning for Hardware Accessibility at Comcast
Designing for Hardware Accessibility at Comcast
 
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
SOQL 201 for Admins & Developers: Slice & Dice Your Org’s Data With Aggregate...
 
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdfIntroduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
 
Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024Enterprise Knowledge Graphs - Data Summit 2024
Enterprise Knowledge Graphs - Data Summit 2024
 
Buy Epson EcoTank L3210 Colour Printer Online.pptx
Buy Epson EcoTank L3210 Colour Printer Online.pptxBuy Epson EcoTank L3210 Colour Printer Online.pptx
Buy Epson EcoTank L3210 Colour Printer Online.pptx
 
Buy Epson EcoTank L3210 Colour Printer Online.pdf
Buy Epson EcoTank L3210 Colour Printer Online.pdfBuy Epson EcoTank L3210 Colour Printer Online.pdf
Buy Epson EcoTank L3210 Colour Printer Online.pdf
 
AI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří KarpíšekAI revolution and Salesforce, Jiří Karpíšek
AI revolution and Salesforce, Jiří Karpíšek
 
Strategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering TeamsStrategic AI Integration in Engineering Teams
Strategic AI Integration in Engineering Teams
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
 
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
 
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdfHow Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
How Red Hat Uses FDO in Device Lifecycle _ Costin and Vitaliy at Red Hat.pdf
 
Connecting the Dots in Product Design at KAYAK
Connecting the Dots in Product Design at KAYAKConnecting the Dots in Product Design at KAYAK
Connecting the Dots in Product Design at KAYAK
 
Optimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through ObservabilityOptimizing NoSQL Performance Through Observability
Optimizing NoSQL Performance Through Observability
 
Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024
 

Repairs questions

  • 1. ‘Repairs’ Questions The ‘Repairs’ database is for a computer repair store. It has four tables: Devices (type, rate, priority) Technicians (Id, name, grade) Experience (Id, type, qualification) Repair (Job, Id, type, owner, date, time, ready, cost) Look in the Devices table and view the different types of repairs (MM stands for Multimedia device, DD means disk drive). Each type of device has a repair rate per ¼ hour spent on it, and a priority level of either low (L), medium (M), or high (H). The Technicians table lists the employees and their skill level. The Experience table shows each technicians ability to repair different devices (Novice (N) or Experienced (E)). The Repair table gives each repair a unique job number, as well as other required data. Create and save SQL queries for the following: 1. Show the name and grade of all technicians 2. Show everything about all devices. 3. Show the different rates that are charged, from lowest to highest (no duplicates). 4. Show all of the jobs (and the type) being worked on by technician 1470. 5. For all multimedia repairs, show the owner and the date of the job. 6. Show all of the jobs that have been around since before the 4th of June. 7. Show the different type of repairs that technician 1470 is working on (no duplicates). 8. Show the different types of devices repaired and the rate charged for each. 9. What is the name of the technician with the ID 1310? 10. Which devices are charged at a rate of $30 per ¼ hour? 11. List the identity numbers of technicians who have expert qualifications.
  • 2. 12. Which devices are ready for collection? 13. What is the level of experience of technician 1470 when working on iMacs? 14. Find the jobs being worked on by technicians 1470 and 1011. 15. The order of ANDs and ORs can affect the result. ANDs are always worked out first. To make sure you get the result you expect, always use brackets. For example, type the following two queries in and see what difference the brackets make: SELECT job, id, type FROM repair WHERE id=1470 OR id=1008 AND type=’iMac’ OR type=’MM’ SELECT job, id, type FROM repair WHERE (id=1470 OR id=1008) AND (type=’iMac’ OR type=’MM’) 16. Show type, rate and priority of devices that have a rate of $20 or $25, and are also either a multimedia device or a disk drive. 17. Show the owners and job dates of all repairs between June 4th and June 6th. 18. Use the In operator to show the rates for input and output devices. 19. Show all of the owners with names beginning with ‘B’. 20. Show any five-letter technician names starting with ‘C’.
  • 3. 21. Show the number of hard drives being repaired. 22. Show the maximum time taken to repair each device type. 23. Edit the previous query to display the maximum time with the heading “Maximum Time” and with the text “quarter hours” appended to the values (e.g. ‘4 quarter hours’). 24. What is the average time each technician takes to complete a job? 25. Show the number of jobs entered on each date. 26. Show the type of devices that have exactly two jobs. 27. List the jobs that have a high priority. 28. Show the ID and name of technicians who are classed as experts. 29. Which high priority devices being worked on by Johnson are ready for collection? 30. What is the date entered for all low priority repairs? 31. Show the device type and repair rate for devices that have technicians who are novices. 32. Which technicians are experts at repairing iMacs? 33. What is the grade of the technician repairing the device owned by James? 34. What will be the charge for the repair to Elliot’s device?
  • 4. 35. Who owns devices being repaired by Ted Carrol? 36. What are the names of the technicians who are still not expert (N) at repairing Macs? 37. What rate will Byrne be charged for repairs? 38. List the owners whose devices have a high priority for repair. 39. What level of qualification has the technician who is doing Taylor’s repair job?