Question

Question 30 Not yet answered Marked out of 1.00 Flag question Question text tblProducts Table ProductID...

Question 30

Not yet answered

Marked out of 1.00

Flag question

Question text

tblProducts Table

ProductID SupplierID CategoryID ProductName
1 1 1 Chai
2 1 1 Chang
3 1 2 Aniseed Syrup
4 2 2 Chef Anto's Cajun

Using the tblProducts Table shown above, which of the following SQL statements returns just the ProductID, CategoryID and ProductName of all the products and order the results by CategoryID?

Select one:

a. Select ProductID, ProductName from tblProducts Order By CategoryID;

b. Select ProductID, CategoryID, ProductName from tblProducts Order By CategoryID;

c. Select ProductID, CategoryID, ProductName from tblProducts Where CategoryID=1 Order By CategoryID;

d. Select ProductID, CategoryID, ProductName Order By CategoryID;

Clear my choice

Question 31

Not yet answered

Marked out of 1.00

Flag question

Question text

tblProducts Table

ProductID SupplierID CategoryID ProductName
1 1 1 Chai
2 1 1 Chang
3 1 2 Aniseed Syrup
4 2 2 Chef Anto's Cajun

Using the tblProducts Table shown above, which of the following SQL statements returns just the ProductID, CategoryID and ProductName of all the products whose ProductID is NOT 2?

Select one:

a. Select ProductID, CategoryID, ProductName from tblProducts;

b. Select ProductID =1, ProductID=3, ProductID=4 from tblProducts;

c. Select ProductID, CategoryID, ProductName from tblProducts Where ProductID <>2;

d. Select ProductID, CategoryID, ProductName from tblProducts Where ProductID = 2;

Clear my choice

Question 32

Not yet answered

Marked out of 1.00

Flag question

Question text

Database systems are used by users, however, users are not considered as a part of a database system.

Select one:

True

False

Question 33

Not yet answered

Marked out of 1.00

Flag question

Question text

Assume that you are dealing with money and you do a lot of calculations that you want them to be exact. Which of the following data types is the best option to store this in a relation?

Select one:

a. integer

b. decimal(10,2)

c. varchar(12)

d. char(12)

Clear my choice

Question 34

Not yet answered

Marked out of 1.00

Flag question

Question text

The JDBC API is a Java API that can access any kind of tabular data, especially data stored in a relational database.

Select one:

True

False

Question 35

Not yet answered

Marked out of 1.00

Flag question

Question text

Students Table
Surname First_Name Student_No Dept_No Year
Duke Fitzroy 1 4 2
Al-Essawy Zaid 2 4 2
Ayton Phil 3 3 1
Patel Mahesh 4 2 1
Jones Gareth 5 2 1
Scott Gavin 6 2 2

CREATE VIEW Freshman
AS Select * From Students Where Year = 2;

Considering the above Students table and Freshman view, what will be the result of the following SQL query:

Select * From Freshman Where Dept_No=2;

Select one:

a.

Surname First_Name Student_No Dept_No Year
Duke Fitzroy 1 4 2
Al-Essawy Zaid 2 4 2

b.

Surname First_Name Student_No Dept_No Year
Patel Mahesh 4 2 1
Jones Gareth 5 2 1
Scott Gavin 6 2 2

c.

Surname First_Name Student_No Dept_No Year
Scott Gavin 6 2 2

d.

Surname First_Name Student_No Dept_No Year
Patel Mahesh 4 2 1
Jones Gareth 5 2 1

Clear my choice

Question 36

0 0
Add a comment Improve this question Transcribed image text
Answer #1

//Solution (30)?

//Option (b) is correct✔

Select ProductID, CategoryID, ProductName from tblProducts Order By CategoryID;

Reason :- > The select statement select the three columns from table tblProducts and returns the query result ordered by Category ID

//Option(a) id incorrect because this query takes only two columns

//Option (c) is incorrect since it returns only those rows which have CatagoryId =1

//Option (d) Wrong query

//Solution (31)?

//Option (C) is correct✔

Select ProductID, CategoryID, ProductName from tblProducts Where ProductID <>2;

//Option (a) is wrong since returns all products Id.

//Option (b) is incorrect

//Option (d) is incorrect (where condition is wrong)

//Solution (32)?

False ✔

//Solution (33) ?

decimal(10,2)✔

//Solution (34) ?

True ✔

//Solution (35)?

Select * From Freshman Where Dept_No=2;

//It means this query select all the freshman whose department number is 2

//So the Correct answer is (b)✔

Add a comment
Know the answer?
Add Answer to:
Question 30 Not yet answered Marked out of 1.00 Flag question Question text tblProducts Table ProductID...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Question 1 Not yet answered Marked out of 1.00 Flag question Question text SQL is a...

    Question 1 Not yet answered Marked out of 1.00 Flag question Question text SQL is a programming language for web-site development. Select one: a. TRUE b. FALSE Question 2 Not yet answered Marked out of 1.00 Flag question Question text Moral dimensions of the information age do NOT include _____. Select one: a. Information rights and obligations b. Accountability and control. c. Information safety d. Property rights and obligations Question 3 Not yet answered Marked out of 1.00 Flag question...

  • Not yet answered Marked out of 1.00 Flag question Question text What is the value of...

    Not yet answered Marked out of 1.00 Flag question Question text What is the value of the following Python expression? not(True and False) Select one: True False Question 2 Not yet answered Marked out of 1.00 Flag question Question text Consider the following Python program. fin = open('words.txt') for line in fin: word = line.strip() print(word) What does the program loop over? Select one: a. Lines in a file b. Lines in a list c. Words in a dictionary d....

  • Question 1 Not yet answered Marked out of 1.00 Flag question Question text Which of the...

    Question 1 Not yet answered Marked out of 1.00 Flag question Question text Which of the following keywords is useful for skipping to the next iteration of a loop? Select one: a. do b. break c. switch d. continue e. while Clear my choice Question 2 Not yet answered Marked out of 1.00 Flag question Question text Consider the following line of Java code. System.out.println("Hello, World!"); "out" is which of the following? Select one: a. a statement b. a class...

  • Question 1 Not yet answered Marked out of 1.00 Flag question Question text A company has...

    Question 1 Not yet answered Marked out of 1.00 Flag question Question text A company has total revenue of $195,000 and total assets on its balance sheet of $2,015,000. What is the return on assets for this company? Select one: a. 10% b. 12% c. 15% d. None of the above Question 2 Not yet answered Marked out of 1.00 Flag question Question text __________ is the return to investors divided by total assets. Select one: a. Return on investment...

  • Question 1 Not yet answered Marked out of 1.00 Flag question Question text A so-called New...

    Question 1 Not yet answered Marked out of 1.00 Flag question Question text A so-called New Gilded Age from 1980–2007 Select one: a. Stagflation from 1973–1980 when all groups lost ground, with real wages for industrial workers declining by 13 percent, and the income of the richest 1 percent dropping by 14 percent b. Stagflation from 1973–1980 when all groups lost ground, with real wages for industrial workers declining by 3 percent, and the income of the richest 10 percent...

  • Question 4 The pH is defined as Not yet answered Marked out of 1.00 P Flag...

    Question 4 The pH is defined as Not yet answered Marked out of 1.00 P Flag question Select one: 0 -log[H] o 10[++] O 10-[H+] O log[H+] Question 5 If the pol of a solution is 4, what is its pH? Not yet answered Marked out of 1.00 Select one: o 7 O 10 p Flag question

  • Question 1 Not yet answered Marked out of 1.00 p Flag question Which of the following...

    Question 1 Not yet answered Marked out of 1.00 p Flag question Which of the following is result of decisions based on inaccurate information? Select one: a. Delivering products to customers on time O b. Meeting customers' demands O c. All the answers d. Misallocation of resources Question 2 Not yet answered Marked out of 1.00 p Flag qu In digital firms, Core business processes are accomplished digitally Select one: a. True о b. FALSE Previous page f Question 7...

  • Energy is always... Question 4 Not yet answered Marked out of 1.00 P Flag question Select...

    Energy is always... Question 4 Not yet answered Marked out of 1.00 P Flag question Select one: o decreasing o lost • conserved o increasing Question 5 When a compound gains energy the process is Not yet answered Marked out of 1.00 Select one: • endothermic P Flag question O hypothermic exothermic hyperthermic o Question 6 Bonus question: heat will pass by conduction and heat will pass by convection and heat will pass by radiation and that's.... Not yet answered...

  • Question 1 Not yet answered Marked out of 1.00 Not flaggedFlag question Question text The statements...

    Question 1 Not yet answered Marked out of 1.00 Not flaggedFlag question Question text The statements inside of a Python loop are known as the ____ of the loop. Select one: a. body b. expression c. counter d. block Question 2 Not yet answered Marked out of 1.00 Not flaggedFlag question Question text The Python 3 program below prints the number 3. s = "Python3" print(s[len(s)]) Select one: True False Question 3 Not yet answered Marked out of 1.00 Not...

  • Not yet answered Graded out of 1.00 Flag question Question text In the process of photosynthesis,...

    Not yet answered Graded out of 1.00 Flag question Question text In the process of photosynthesis, water and carbon dioxide are produced. Select one: True False Question 2 Not yet answered Graded out of 1.00 Flag question Question text In the carbon cycle, combustion produces atmospheric oxygen. Select one: True False Question 3 Not yet answered Graded out of 1.00 Flag question Question text In a balanced chemical equation, the number of each type of atom in the reactants must...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT