Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

im not getting the correct output for the test case using the given code / * Enter your query below. Please append a semicolon

im not getting the correct output for the test case using the given code
/*
Enter your query below.
Please append a semicolon ";" at the end of the query
*/
SELECT
sender,
MIN(dt) AS sequence_start,
MAX(dt) AS sequence_end,
COUNT(*) AS transactions_count,
ROUND(SUM(amount),6) AS transactions_sum
FROM
transactions
GROUP BY
sender,
FLOOR(UNIX_TIMESTAMP(dt)/3600)
HAVING
transactions_count >=2
AND transactions_sum >=150
ORDER BY
sender ASC,
sequence_start ASC,
sequence_end ASC;
image text in transcribed

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

Database Fundamentals Study Guide

Authors: Dr. Sergio Pisano

1st Edition

B09K1WW84J, 979-8985115307

More Books

Students also viewed these Databases questions

Question

r o nn()ANn2 TI

Answered: 1 week ago