Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Which of the following queries would check for duplicates of a customer _ id , their complete addresses and totals in the invoice table, and

Which of the following queries would check for duplicates of a customer_id, their complete addresses and totals in the invoice table, and how many there are of each?
a.)
SELECT *, COUNT(*)
FROM invoice
GROUP BY *
HAVING COUNT(*)>1;
b.)
SELECT billing_address, billing_city, billing_state, billing_country, billing_postal_code, total, customer_id
FROM invoice
GROUP BY billing_address, billing_city, billing_state, billing_country, billing_postal_code, total, customer_id
HAVING COUNT(*)>1;
c.)
SELECT billing_address, billing_city, billing_state, billing_country, billing_postal_code, total, customer_id, COUNT(*)
FROM invoice
GROUP BY billing_address, billing_city, billing_state, billing_country, billing_postal_code, total, customer_id
HAVING COUNT(*)>1;
d.)
SELECT customer_id, COUNT(*)
FROM invoice
GROUP BY customer_id
HAVING COUNT(*)>1;

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

Oracle RMAN For Absolute Beginners

Authors: Darl Kuhn

1st Edition

1484207637, 9781484207635

More Books

Students also viewed these Databases questions