Question: Can you please help me with this following question: Write an SQL query to show all people involved in this business and their role (customer

Can you please help me with this following question: Write an SQL query to show all people involved in this business and their role (customer or salesman). Return ID, name, and role.

Here is my SQL query. I don't know how to merge customer and salesman into a column role with each row (people) having its respective role (customer or salesman)

Can you please help me with this following question: Write an SQL

query to show all people involved in this business and their role

Consider the following tables (Salesman and Customer, respectively). SELECT Custoner.custoner_id as ID, Customer.cust_nane as Name FrOM Custamer UNION SELECT salesman_id as ID, Salesman, name as Name FRON Salesman

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!