Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

PRINT Lab Week 2, Question 1 What channel is SYFY? --------------------- Write a SELECT statement that finds the channels named SYFYP and SYFYHDP in the

PRINT Lab Week 2, Question 1 What channel is SYFY? --------------------- Write a SELECT statement that finds the channels named SYFYP and SYFYHDP in the CHANNEL table of the TV database. Use a WHERE clause with an OR statement to return only these two channels. Display only the ChannelNumber and DisplayName columns. Hint: Correct results will look like this (note that DisplayName is 200 characters wide, so I''ve edited a bit): ChannelNumber DisplayName ------------- ----------- 59 SYFYP 1411 SYFYHDP ' + CHAR(10) GO -- -- [Insert your code here] --
PRINT Lab Week 2, Question 2: What channel is OPB? --------------------- Write a SELECT statement that finds all the channels with OPB in the display name. Use a WHERE clause with LIKE and wildcards to find all matching channels. Display only the ChannelNumber and DisplayName columns. This time, use CONVERT to make the DisplayName be 10 characters wide. Use AS to give your column a name. Display results in ascending order by ChannelNumber. Hint: Correct results will look like this: ChannelNumber ChannelName ------------- ----------- 10 KOPB 1010 KOPBDT 1165 KOPBDT2 1166 KOPBDT3 ' + CHAR(10) GO -- -- [Insert your code here] -- 

using Microsoft SQL Server Management Studio 2012 (or later)

or DataGrip

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions