hello people
I have 2 tables, employee and engineer.
I need to get all the details from employee for the employee number obtained from engineer
the employee table has both operators and engineers details and the only way they are distinguishable is through the engineer table which has a primary foreign key of employee number so
IF engineer.emplyeeNumber == employee.employeeNumber THEN Give details
fields are as follows
EMPLOYEE
--------------
EmployeeNumber
Phone
Email
ENGINEER
-------------
EmployeeNumber
Specialise
and i need to create a view that shows the engineers with what they specialise in and thier details i have currently
CREATE VIEW specialise AS
SELECT * FROM employee WHERE employeenumber = (SELECT employeeNumber FROM engineer);
but i get the error of "single row subquery returns multiple rows"
please help
Steve
Enter your message below
Sign in or Join us (it's free).