proc sql SAS 5. Creating and Using a View to Provide Consolidated Information Cr
ID: 3702001 • Letter: P
Question
proc sql SAS 5. Creating and Using a View to Provide Consolidated Information Create a view named orion.t shirts containing the following columns: . Productull a. Supplier Name (formatted as $20.) Product Name. . Price (label it Retail Price.) Use data from the following tables. (Columns of interest are in parentheses. . orion.product.dim (Product ID, Product Name, Supplier. Name) . grion.price list (Product ID. Unit Sales Price) Select only those records where Product. Name includes the word T-Shirt.Explanation / Answer
Please find answer of 5 (A) as below
create view orion.t_shirts
AS
SELECT Product_ID, Supplier_Name,Product_Name,Price as 'Retail Price'
FROM orion.product_dim INNER JOIN orion.price_list
ON orion.product_dim.Product_ID = orion.price_list .Product_ID
WHERE orion.product_dim.Product_Name='T-Shirt'
Please find answer of 5 (B) as below
SELECT
Product_ID as 'Product ID' ,
Supplier_Name as 'Supplier Name',
Product_Name as 'Product Name',
'$' + CONVERT(varchar(12), [Retail Price], 1) AS [Retail Price]
FROM orion.t_shirts
order by Product_ID,Supplier_Name
Please find answer of 5 (C) as below
SELECT
Product_ID as 'Product ID' ,
Product_Name as 'Product Name',
'$' + CONVERT(varchar(12), [Retail Price], 1) AS [Retail Price]
FROM orion.t_shirts
where [Retail Price] < 20
order by [Retail Price]
BEST OF LUCK !!!
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.