Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Sales 1 Computer Brand PK IDComputerBrand char(6) ComputerBrandName varchar(100) 1 Computer PK IDComputer char(6) FK IDComputerBrand char(6) ComputerBrand varchar(100) ComputerName varchar(100) Computer Price int 1

image text in transcribed

image text in transcribed

Sales 1 Computer Brand PK IDComputerBrand char(6) ComputerBrandName varchar(100) 1 Computer PK IDComputer char(6) FK IDComputerBrand char(6) ComputerBrand varchar(100) ComputerName varchar(100) Computer Price int 1 Supplier PK Supplier char(6) FK IDComputer char(6) SupplierName varchar(100) SupplierContact Number varchar(20) Supplier Address varchar(100) 1- PK IDSales char(6) SalesName varchar(100) SalesDate of Birth date SalesGender varchar(100) Sales ContactNumber varchar(20) SalesAddress varchar(100) SalesSalary int 1 1 1 1 1.. 1- Client char(6) char(6) varchar(100) date varchar(20) varchar(100) varchar(100) PK JIDClient FK IDComputer ClientName ClientDate of Birth CientGender ClientEmail ClientAddress 1.. Sales Transaction PK DSales Transaction char(6) () FK IDSales char(6) FK IDClient char(6) TransactionDate Sales date Computer Sold int QuantityOfSales int 1. Buying Transaction PK IDBuying Transaction char(6) FK IDSales char(6) FK Supplier Transaction DateBuying date Buying Computer int QuantityOIBuying int char(6) 1. Question Database SQL Subquery The erd provides an explanation of sales transactions to clients and buying transactions from suppliers. Then there is a case below that must be solved with a sql query (Subquery). Show (use SELECT in SELECT) IDComputerBrand, ComputerBrand, IDClient, ClientEmail (get from replace format email to '@max.com'), Quantity (get from sum Quantity of computers of the Brand) for the highest Quantity of the brand, client that has the email format '@yahoo.com' and IDClient ending in odd number

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

Professional Visual Basic 6 Databases

Authors: Charles Williams

1st Edition

1861002025, 978-1861002020

More Books

Students also viewed these Databases questions

Question

LO3 Name the seven categories of HR functions.

Answered: 1 week ago