A Guide to SQL
9th Edition
ISBN: 9781111527273
Author: Philip J. Pratt
Publisher: Course Technology Ptr
expand_more
expand_more
format_list_bulleted
Concept explainers
Question
Chapter 6, Problem 3SCG
Program Plan Intro
UPDATE command:
- The “UPDATE” command is employed to update information present in a table.
- It is always used with SET keyword either in bulk or individually.
Syntax for update the value in the table is given as follows:
The Syntax for update the value in the table is given below:
UPDATE table_name
SET column1 = data1, column2 = data2, ...
WHERE condition;
Expert Solution & Answer
Trending nowThis is a popular solution!
Students have asked these similar questions
Using software.subscriptions table, pull all columns for subscriptions that have been cancelled.
Some rows of the STUDENT table are shown below:
CODE
NAME
GPA
YEAR
291
ALEX
3.1
2
938
MICHELE
2.3
1
931
JHON
3.3
1
182
JOE
3.4
2
190
REY
2.0
2
330
RON
3.9
3
Which best describes the result of the query below?
SELECT YEAR, AVG(GPA) FROM STUDENT WHERE GPA > 2.0 GROUP BY YEAR
a.
The average maximum GPA of all the students in each year.
b.
The year of the student with the maximum GPA.
c.
The average GPA of students with a GPA higher than 2.0 each year.
d.
The average GPA of the students with a GPA higher than 2.0.
Add a column named ON_HAND_VALUE to the NONCAT table. The on-hand value is a seven-digit number with two decimal places that represents the product of the number of units on hand and the price. Then set all values of ON_HAND_VALUE to ON_HAND * PRICE.
Chapter 6 Solutions
A Guide to SQL
Ch. 6 - Prob. 1RQCh. 6 - Which command and clause adds an individual row to...Ch. 6 - How do you add data from an existing table to...Ch. 6 - Prob. 4RQCh. 6 - Which command removes rows from a table?Ch. 6 - Which command makes updates permanent?Ch. 6 - Which command reverses updates? Which updates are...Ch. 6 - Prob. 8RQCh. 6 - What is the format of the SET clause that changes...Ch. 6 - Which command and clause adds a column to an...
Ch. 6 - Prob. 11RQCh. 6 - Which command deletes a table and all its data?Ch. 6 - Prob. 13RQCh. 6 - Prob. 1TDCh. 6 - Prob. 2TDCh. 6 - Prob. 3TDCh. 6 - Prob. 4TDCh. 6 - Prob. 5TDCh. 6 - Prob. 6TDCh. 6 - In the NONGAME table, change the category for item...Ch. 6 - Prob. 8TDCh. 6 - Prob. 9TDCh. 6 - Prob. 10TDCh. 6 - Prob. 11TDCh. 6 - Use SQL to make the following changes to the...Ch. 6 - Prob. 2CATCh. 6 - Prob. 3CATCh. 6 - Prob. 4CATCh. 6 - Prob. 5CATCh. 6 - Prob. 6CATCh. 6 - Add to the PADDLING table a new character column...Ch. 6 - Prob. 8CATCh. 6 - Prob. 9CATCh. 6 - Prob. 10CATCh. 6 - Prob. 11CATCh. 6 - Prob. 12CATCh. 6 - Use SQL to make the following changes to the...Ch. 6 - Prob. 2SCGCh. 6 - Prob. 3SCGCh. 6 - Prob. 4SCGCh. 6 - Prob. 5SCGCh. 6 - Prob. 6SCGCh. 6 - Prob. 7SCGCh. 6 - Prob. 8SCGCh. 6 - Prob. 9SCGCh. 6 - Prob. 10SCGCh. 6 - Prob. 11SCGCh. 6 - Prob. 12SCG
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- Add the following record to the VACATION_UNIT table: condo ID: 20; location number: 2; unit number: A04; square feet: 1680; bedrooms: 3; bathrooms: 3; condo fee: 775; and owner number: BL720. Display the contents of the VACATION_UNIT table.arrow_forwardAdd a column named ON_HAND_VALUE to the NONCAT table. The on-hand value is a seven-digit number with two decimal places that represent the product of the number of units on hand and the price. Then set all values of ON_HAND_VALUE to ON_HAND * PRICE.arrow_forwardUsing F_STAFFS table, write a query that will display First_name and maximum salary of staffswith the column name “HighSalary”, whose first_name contain letter ‘u’, for eachFirst_Name, whose maximum salary is less than 10. Arrange it by Last_name from z to a.arrow_forward
- Use a subquery to find employees' last names and hire date from the employees table whose manager is named "Hunold".arrow_forwardhow is duplicate column prefixed when duplicate column appear in Join Query? a) Table name followed by period b) Table name followed by plus c) Table name followed by equal d) Table name followed by space abd then column namearrow_forwardYou will be using the Colonial Adventure Tours database. Find the trip name of all reservations for hiking trips and sort the results by trip name in ascending order.arrow_forward
- The sales person gets a bonus pay if their amount exceeds a certain tier level for each year. Write a query that shows who would be getting a bonus and for how much. How many rows will it return and with what data?arrow_forwardWrite a query that returns all customers listed in the orders table who placed orders on the most recently recorded day, return the OrderID, the CustomerID and the OrderDate .arrow_forwardEmployee_id Name Salary 1001 Annie 6000 1009 Ross 4500 1018 Zeith 7000 This is Employee table. Which of the following employee_id will be displayed for the given query? SELECT * FROM employee WHERE employee_id>1009; a) 1009, 1001, 1018 b) 1009, 1018 c) 1001 d) 1018arrow_forward
arrow_back_ios
arrow_forward_ios
Recommended textbooks for you
- A Guide to SQLComputer ScienceISBN:9781111527273Author:Philip J. PrattPublisher:Course Technology PtrNp Ms Office 365/Excel 2016 I NtermedComputer ScienceISBN:9781337508841Author:CareyPublisher:Cengage
A Guide to SQL
Computer Science
ISBN:9781111527273
Author:Philip J. Pratt
Publisher:Course Technology Ptr
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:9781337508841
Author:Carey
Publisher:Cengage