QuestionQ118

VerifiedDisplaying Data from Multiple Tables

Review the data in the BRICKS table:

Question Image

Review the BOXES table:

Question Image

Which two queries return only CUBE?

Choose two
Explanation

For the SMALL box, the permitted half-open range is weight greater than or equal to 0 and less than 10. Only CUBE, with a weight of 5, satisfies that range; CUBOID is 10 and is excluded by < max_weight, while CYLINDER is 15. BETWEEN is inclusive at both bounds, so it would also include CUBOID. Oracle documents BETWEEN as equivalent to lower <= value AND value <= upper.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!