e an equivalent query using normal SQL constructs, without using the tumbling window operator. You can assume that the timestamp can be converted to an integer value that represents

Oracle 12c: SQL
3rd Edition
ISBN:9781305251038
Author:Joan Casteel
Publisher:Joan Casteel
Chapter12: Subqueries And Merge Statements
Section: Chapter Questions
Problem 19MC
icon
Related questions
Question

Consider the following query using the tumbling window operator: select item, System.Timestamp as window end, sum(amount) from order timestamp by datetime group by itemid, tumblingwindow(hour, 1).

Give an equivalent query using normal SQL constructs, without using the tumbling
window operator. You can assume that the timestamp can be converted to an integer
value that represents the number of seconds elapsed since (say) midnight, January 1,
1970, using the function to_ seconds(timestamp). You can also assume that the usual
arithmetic functions are available, along with the function floor(a) which returns the
largest integer ≤a.

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
SQL Query
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Oracle 12c: SQL
Oracle 12c: SQL
Computer Science
ISBN:
9781305251038
Author:
Joan Casteel
Publisher:
Cengage Learning