Business Questions

1. Create a table named 'SalesRecord' with columns "City, Country, Items, UnitsSold, UnitPrice, UnitCost, TotalRevenue , TotalCost, Year, Month, Status , Quarter" and data types CHAR(25), CHAR(25), CHAR(25), INT, FLOAT, FLOAT, FLOAT, FLOAT, NT, INT, CHAR(25), INT

2. Insert values into the table (SalesRecord) from the given table below.

3. Write a SQL query to print the cities that are only from France (It could be duplicate)

4. Write a SQL query to print items, country, and unit cost whose unit cost more than 100

5. Write a SQL query to print all records from USA order by 'TotalRevenue' in descending order

6. Write a SQL query to print 'City, Items, UnitsSold and Year' where UnitsSold lies between 3000 and 7000.

7. Write a SQL query to fetch minimum revenue and maximum revenue.

8. Write a SQL query to print top 10 records by 'TotalCost'

Given Table

City

Country

Items

Units Sold

Unit Price

Unit Cost

Total Revenue

Total Cost

Year

Month

Status

Quarter

NYC

USA

Cosmetics

8446

437.2

263.33

3692591

2224085

2014

10

Shipped

1

Reims

France

Vegetables

3018

154.06

90.93

464953

274427

2011

11

Shipped

2

Paris

France

Baby Food

1517

255.28

159.42

387260

241840

2016

10

Shipped

3

Pasadena

USA

Cereal

3322

205.7

117.11

683335

389039

2010

4

Shipped

3

San Francisco

USA

Fruits

9845

9.33

6.92

91853.9

68127.4

2011

8

Shipped

4

Burlingame

USA

Cereal

9528

205.7

117.11

1959910

1115824

2014

11

Shipped

4

Lille

France

Cereal

2844

205.7

117.11

585011

333061

2015

3

Shipped

4

Bergen

Norway

Clothes

7299

109.28

35.84

797635

261596

2012

5

Shipped

4

San Francisco

USA

Vegetables

2428

154.06

90.93

374058

220778

2015

1

Shipped

4

Paris

France

Vegetables

4800

154.06

90.93

739488

436464

2013

12

Shipped

1

Melbourne

Australia

Clothes

3012

109.28

35.84

329151

107950

2015

12

Shipped

1

NYC

USA

Snacks

2694

152.58

97.44

411051

262503

2010

2

Shipped

2

Newark

USA

Household

1508

668.27

502.54

1007751

757830

2016

11

Shipped

2

Bridgewater

USA

Cosmetics

4146

437.2

263.33

1812631

1091766

2015

12

Shipped

2

Nantes

France

Fruits

7332

9.33

6.92

68407.6

50737.4

2011

1

Shipped

3

Cambridge

USA

Clothes

4820

109.28

35.84

526730

172749

2010

6

Shipped

3

Helsinki

Finland

Office Supplies

2397

651.21

524.96

1560950

1258329

2016

4

Shipped

3

Stavern

Norway

Beverages

2880

47.45

31.79

136656

91555.2

2012

7

Shipped

4

Allentown

USA

Clothes

1117

109.28

35.84

122066

40033.3

2014

9

Shipped

4

NYC

USA

Household

8989

668.27

502.54

6007079

4517332

2012

8

Shipped

4

Salzburg

Austria

Snacks

407

152.58

97.44

62100.1

39658.1

2012

9

Shipped

4

Chatswood

Australia

Clothes

6313

109.28

35.84

689885

226258

2010

8

Shipped

4

Nantes

France

Personal Care

9681

81.73

56.67

791228

548622

2011

2

Shipped

1

New Bedford

USA

Clothes

515

109.28

35.84

56279.2

18457.6

2015

12

Shipped

1

Liverpool

UK

Cereal

852

205.7

117.11

175256

99777.7

2012

10

Shipped

2

Madrid

Spain

Beverages

9759

47.45

31.79

463065

310239

2017

1

Disputed

2

Stavern

Norway

Beverages

8334

47.45

31.79

395448

264938

2014

10

Shipped

1

Lule

Sweden

Fruits

4709

9.33

6.92

43935

32586.3

2012

1

Shipped

1

Madrid

Spain

Meat

9043

421.89

364.69

3815151

3297892

2016

1

Shipped

2

Burlingame

USA

Personal Care

8529

81.73

56.67

697075

483338

2016

1

Shipped

3

Academic Honesty!
It is not our intention to break the school's academic policy. Posted solutions are meant to be used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly complete the form. Please provide a valid email address and we will get back to you within 24 hours. Payment is through PayPal, Buy me a Coffee or Cryptocurrency. We are a nonprofit organization however we need funds to keep this organization operating and to be able to complete our research and development projects.