1. What commands would return all the rows and columns in the ProductCategory ta
ID: 670473 • Letter: 1
Question
1. What commands would return all the rows and columns in the ProductCategory table?
2. What commands would you type and execute to return only the ProductSubcategoryID, ProductCategoryID, Name, and ModifiedDate columns?
3. What commands would you type and execute to return rows where the word bike appears somewhere in the Name column?
4. In the existing query window, what commands would you use to add a column alias to the Name column to clarify it as the subcategory name?
5. In the existing query window, what command would you use to sort the previous result set?
Explanation / Answer
1. SELECT * FROM ProductCategory
2. SELECT ProductSubcategoryID, ProductCategoryID, Name,ModifiedDate
FROM ProductCategory
3. SELECT * FROM ProductCategory WHERE name like '%bike%'
4. SELECT name as subcategoryname from ProductCategory
5. SELECT name as subcategoryname from ProductCategory
ORDER BY name
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.