Due within 24 hours Introduction to Database: MicrosoftSQL server Note: If you r
ID: 672239 • Letter: D
Question
Due within 24 hours
Introduction to Database: MicrosoftSQL server
Note: If you really know this stuff then please do this otherwise do not post wrong answer as I've gotten one of the wrong answers here.
Scenario 3-1: Using the SELECT Command
You have just have been hired as a database administrator for the AdventureWorksCorporation. A network administrator wants to know how to extract information from theAdventureWorks database. Therefore, you need to answer the following questions:
What command would you use to display records from a table?
What command would you use to display a FirstName and LastName from the Users table?
What command would you use to display all records from the Member database andhave it sorted by the Name column?
What command would you use to display all records from the Suppliers table that havethe City of Sacramento?
What command would you use to display the CompanyName, ContactName, andPhoneNumber from the Suppliers table with Supplier ID greater than 1000?
What command would you use to display CompanyName, ContactName, and PhoneNumber from the Customers table for companies that have more than 100 employeesand reside in the state of California?
Scenario 3-3: Manipulating Data Using SELECT and JOIN Statements
You are a database administrator for the AdventureWorks Corporation. Some confusionhas arisen because the company’s purchase orders are stored in two tables. Therefore,you need to write a query to join the PurchaseOrderHeader table in the sample database,AdventureWorks, to itself in order to provide a list of purchase orders paired together. Eachrow includes two purchase orders that have identical vendors and shipping methods.
After opening SSMS and accessing the AdventureWorks database, what query wouldyou use against the AdventureWorks database to display the ProductSubcategoryIDand ProductCategoryID from the Production.ProductSub table that contain the word“Bike”? You also want to sort by Subcategory Name.
What query would you use to join the ProductCategory table to the ProductSubcategorytable in order to retrieve the Name column from within the ProductCategory table?
Explanation / Answer
Select * from suppliers where cityname=’ Sacramento’;
SELECT companyname,contactname,phonenumber from suppliers where supplierid > 1000;
SELECT companyname,contactname,phonenumber from customers where state=’california’;
SELECT _id, vendors,shippingmethods FROM purchasesorderheader
NATURAL JOIN adventureworks;
Select ‘category’,c.name from product category as c union all select ‘subcategory,s.name’
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.