Task 4 (Due at the end of Week 6)
Develop a query that will identify and mark inactive those customers that have bills overdue by more than 30 days (this can usually be done using a sub-query). Remember, you are only marking a customer as inactive, not actually deleting the customer record from the system.
To submit this task, create a heading called MODIFY STATEMENTS in your group project SQL script, and name the file TEAM_X_TASK4.TXT. This should be the same script that contains your DROP TABLE, CREATE TABLE, and INSERT statements. Once you have verified that your SQL statement or statements work, create a spooled output showing the results of your statements.
Terri Smith has contacted you with regard to an advertisement you had in the Age promoting your company’s expertise in database design and implementation. Ms. Smith is the Managing Director of MiniQuest, a broadcasting company based in Melbourne, Texas, that broadcasts television via cable to a six-county area in Texas. From your discussion with Ms. Smith, you have identified the following information about the company:
• MiniQuest currently has ten channels of five distinct types (2 Movie Channels, 2 News Channels, 2 Lifestyle Channels, 2 Documentary Channels, and 2 Sport Channels). Each channel shows programs on a 24-hour basis. Programs can appear on either of the two channels in a category or on both channels at any time.
• A guide (Weekly Showing) is produced that lists all the programs on each channel on a daily basis. Currently all the program scheduling for MiniQuest is done manually based on the day the program is to air and the length of the program provided by the supplier. Once this is done, the guides are produced. When the Weekly Showing guide is produced, MiniQuest finds it difficult to work out when a program finishes so that it can determine when the next program starts. The Weekly Showing guide is currently mailed to all customers, but Ms. Smith wants to e-mail it in the future to all customers (who get a free e-mail account).
• In addition to the programming problem, MiniQuest is experiencing the need to keep track of its customers in a better manner (it currently has paper cards and is doing this manually). Furious customers have been reporting that they have been getting fewer channels than they have paid for. As such, MiniQuest wants to incorporate the customer information and the programming information into one database that will produce a daily guide of shows to be sent to customers via e-mail. This guide could then be personalized to only list the shows that the customer is paying for. In addition, only those channels being paid for will be broadcast to that customer’s home.
• Ms. Smith has instigated a customer survey to determine which channel is the favorite for each customer. The result of this survey needs to be stored in the database along with the date of the survey.
• Billing information also needs to be stored in the database. This information includes the billing date (either the 1st or 15th of the month, depending on when the customer signed up), the package(s) the customer has subscribed to (this determines the channels the customer receives – see Table 1), the amount to be paid monthly (based on the package(s) subscribed to), and whether the bill has been paid. Bills are currently sent on a monthly basis. These are currently sent by mail, but will be sent via e-mail in the future.
• Ms. Smith has visions about how the system will operate on a daily basis. (This information is included so that you can get a feel for how the business operates. It should also give you some idea about how the interface would operate between the operator and your database. YOU ARE NOT REQUIRED TO CONSTRUCT AN INTERFACE FOR THIS PROJECT.)