Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

This is the part of e that I have written out, please help me to edit it or point out my problems select TEAM_MEMBER.MEMBERID, TEAM.TEAMNAME,

This is the part of e that I have written out, please help me to edit it or point out my problems
select TEAM_MEMBER.MEMBERID,
TEAM.TEAMNAME,
EMPLOYEE.EPHONE,
EMPLOYEE.ENAME,
EMPLOYEE.EEMAIL,
FRANCHISE_APP.DECISIONDATE
from MEMBERSHIP
inner join TEAM on MEMBERSHIP.TEAMID = TEAM.TEAMID(
from TEAM inner join FRANCHISE_APP on FRANCHISE_APP.TEAMID = TEAM.TEAMID)
inner join FULL_TIME_EMPLOYEE on MEMBERSHIP.MEMBERID = FULL_TIME_EMPLOYEE.MEMBERID (
from FULL_TIME_EMPLOYEE inner join FULL_TIME_EMPLOYE.EEMPLOYEEID = EMPLOYEE.EMPLOYEEID)
where FRANCHISE_APP.STATUS ='Granted'
UNION
select
SHAREHOLDER.SHID
SHAREHOLDER.SHNAME
SHAREHOLDER.SHPHONE
SHAREHOLDER.SHEMAIL
FRANCHISE_APP.DECISIONDATE
from SHAREHOLDER
inner join MEMBERSHIP on SHAREHOLDER.MEMBERID = MEMBERSHIP.MEMBERID
(from MEMBERSHIP inner join TEAM on MEMBERSHI.TEAMID= TEAM.TEAMID)
image text in transcribed
image text in transcribed
The list of tables available for this assignment is the following: STORE (StoreID, StoreAddress, WeekDaysHours, WeekendHours) ACCOUNT (AccountNo., AccountName, Balance) DEPARTMENT (DepartmentID, DepartmentTitle, NoOfEmployees, AccountNo, StoreID, FranchiseTeamID) FRANCHISE_APP (AppNumber, AppDate, DecisionDate, Status, DepartmentID, TeamID) EMPLOYEE (EmployeeID, Name, Phone, Email, Address, Gender, DOB, JoiningDate, Centralorlocalemployment, EFTPOSID, CANumber, DepartmentID) CASUAL_EMPLOYEE (EmployeeID, HourlyRate) PART_TIME_EMPLOYEE (EmployeeID, WeeklyHours, Salary) FULL_TIME_EMPLOYEE (EmployeeID, LeaveDays, Salary, MemberID) TEAM MEMBER (MemberID) SHARHOLDER (H.ID, Name, Phone, Email, Address, NoofShares, MemberID) TEAM (TeamID, TeamName, TeamLeaderID) MEMBERSHIP (MemberID, TeamID, Percentageofshare) NOTE: PK is printed underlined and FK is printed italic in italics. e. List the team member details (including shareholder and employee details such as id, name, phone and email) for all the team members who are part of a franchise team of a successful application. For each of the members, also include the date on which their franchise application was granted. Hint: use UNION. f. List the team member details (member id and team id) who has the maximum credit to his name, based on his percentage of share in the team and the positive account balance of the franchising department (Hint: account balance can be found in the Account table). Please note, it is safe to assume that only one team member has the highest percentage of share

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

More Books

Students also viewed these Databases questions