SQL query question
Well I’m stuck…. I have a database with two tables, Productsand salesman. I am tasked with displaying the salesman_Firstname,salesman_Lastname colums from the salesman table as well as theProducts_Price column from the Products table. I need only displaythe records where the totals (sum) of the Products_Price is greaterthan 10,000 for each salesman and order by the totals of theProducts_Price. I know i need to use the join clause in thisinstance and the SUM(Products_Price) > 10000 statement but ijust cant seem to make it work.. any help would be muchappreciated.
Sorry the linking relationship between tables is salesman_ID (products.salesman_ID and salesman.salesman_ID). There is a thirdtable but i didnt think it was relevant as i all the information ihave been asked to display is only in the products and salesmantables. the third table is departments (dept_ID, dept_name,dept_address, dept_phone) This table contains no relationships tothe other 2 tables.