Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Consider the database model below: The database model FIGURE 7.1 CUSTOMER INVOICE LINE PK CUS.CODErales generatesINV NUMBER CUS LNAME CUS_FNAME CUS INITIAL CUS AREACODE CUS

image text in transcribed
image text in transcribed
Consider the database model below: The database model FIGURE 7.1 CUSTOMER INVOICE LINE PK CUS.CODErales generatesINV NUMBER CUS LNAME CUS_FNAME CUS INITIAL CUS AREACODE CUS PHONE CUS BALANCE NV DATE LINE UNITS LINE PRICE is found in VENDOR PRODUCT PK P CODE V NAME VCONTACT supplies P DESCRIPT P INDATE - AREACODE V PHONE V STATE V ORDER P.MIN P PRICE P DISCOUNT FK1 V CODE Write the SQl code for creating the database and all the above tables. State all primary keys and foreign keys constraints. PHONE(strings), CUSR BALANCE(numeric) VENDOR: V-CODE (integer), V_NAME, VCONTACT, v_AREACODE, v_PHONE, V_STATE, V_ORDER(string) PRODUCT: P-DESCRIPT (String. P-INDATE (date), P-QOH, P.MIN, P-PRICE, DiscouNT(numeric. INVOICE: INV_NUMBER (numeric), INV_DATE (date) LINE: LINE NUMBER, LINE UNITS, LINE PRICE (numeric), P_CODE(string) Write the SQL queries to retrieve the following: 1) The description, quantity on hold(P QOH), the minimum quantity and the price for each product whose price is below $10.00 2) The description, quantity on hold[P_Q0H), the minimum quantity, the price and the date for each product whose inventory date (P INDATE) is on or after January 20, 2012

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

Database Design And Relational Theory Normal Forms And All That Jazz

Authors: Chris Date

1st Edition

1449328016, 978-1449328016

More Books

Students also viewed these Databases questions