Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

can you write me general SQL queries for the questions below. You can use placeholders for the table, row and column names. Members who registered

can you write me general SQL queries for the questions below. You can use placeholders for the table, row and column names.

  1. Members who registered after 2017 Jan 1. Columns and format:

Name (Last, first)

email

Date Joined (i.e., registered date)

phone # (areacode-xxx-xxxx)

Home City

  1. Student who has signed up to join AITP (have a valid registered date) but have not paid member fees (no payment exists)

Name (Last, first)

email

Date Joined (i.e., registered date)

phone # (areacode-xxx-xxxx)

Home City

  1. Members whose membership will expire within 30 days from today

Member ID

Name (Last, first)

email

phone # (areacode-xxx-xxxx)

Last time payment (i.e., Latest payment date)

Number of days to expire

Is last time payment a renew?

  1. Members whose membership will expire within 3 months from today

Member ID

Name (Last, first)

email

phone # (areacode-xxx-xxxx)

Last time payment (i.e., Latest payment date)

Number of days to expire

Is last time payment a renew?

  1. Members whose membership have already expired

Name (Last, first)

email

Date Joined (i.e., registered date)

phone # (areacode-xxx-xxxx)

Home City

  1. Members who have ordered polo shirt but have not received it

Member ID

Name (Last, first)

email

phone # (areacode-xxx-xxxx)

Shirt order date

Shirt order payment date

Shirt order payment amount

Shirt received? (show a N in resulting records)

  1. All current members
    1. Exclude the expired members
    2. Columns and format:

Member ID

Name (Last, first)

email

phone # (areacode-xxx-xxxx)

Latest payment date

Earliest payment date

Number of payments

Average payment amount

  1. Design SQLs to answer managerial questions:
    1. Has the number of members increasing or decreasing year by year?
    2. How many members has renewed their membership in each year?
    3. How many members paid their fee by cash, card, check or other types in each year?
    4. List new members of year 2017 and total number of polo shirts each member have ordere

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

T Sql Window Functions For Data Analysis And Beyond

Authors: Itzik Ben Gan

2nd Edition

0135861446, 978-0135861448

More Books

Students also viewed these Databases questions

Question

please dont use chat gpt 3 4 4 .

Answered: 1 week ago

Question

WHAT IS AUTOMATION TESTING?

Answered: 1 week ago

Question

What is Selenium? What are the advantages of Selenium?

Answered: 1 week ago

Question

Explain the various collection policies in receivables management.

Answered: 1 week ago