subject

Retrieve the names of employees who work on exactly one project that is controlled by their department. (It does not matter how many non-departmental projects they work on.) Also show the department name, and the project name and location. Show results in ascending alpha order (by last name and then first name).
Column Headings: FNAME LNAME DNAME PNAME PLOCATION

I currently have a list of names who work on projects controlled by their departments. But I am unsure on how to trim down the table so that it shows the employees who work on exactly one project controlled by there department. (ie, james borg and jennifer wallace). Values are subject to change, so i can not just do a direct comparison to their last names or something.

SQL Query I produced:

select distinct fname, lname, dname, pname, plocation
from works_on, project, employee, department
where works_on. pno = project. pnumber
and works_on. essn = employee. ssn
and project. dnum = employee. dno
and department. dnumber = employee. dno
order by lname, fname;

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 22:00
What do the principles of notice, choice, onward transfer, and access closely apply to? a. privacyb. identificationc. retentiond. classification
Answers: 1
question
Computers and Technology, 22.06.2019 11:40
Design a pos circuit that displays the letters a through j on a seven-segment indicator. the circuit has four inputs w, x, y, and z which represent the last 4 bits of the uppercase ascii code for the letter to be displayed. thus, if wxyz = 0001 then "a" will be displayed. (any answer with 22 or fewer gates and inverters, not counting any for the inputs, is acceptable)
Answers: 2
question
Computers and Technology, 22.06.2019 20:00
Which location-sharing service offers items for users as a gaming component and also allows them to collectively link their check-ins to publish a trip? a. whrrl b. buzzd c. foursquare (this option is wrong i already tried) d. gowalla for plato
Answers: 2
question
Computers and Technology, 23.06.2019 16:30
What is one reason why indoor air pollution has become an increasing problem.
Answers: 1
You know the right answer?
Retrieve the names of employees who work on exactly one project that is controlled by their departme...
Questions
question
Mathematics, 28.09.2020 14:01
question
Mathematics, 28.09.2020 14:01
question
Health, 28.09.2020 14:01
question
History, 28.09.2020 14:01
question
History, 28.09.2020 14:01
Questions on the website: 13722367