programming-examples/sql/View/3. Write a query to find the salesmen of the city New York who achieved the commission more than 13%.sql

14 lines
360 B
MySQL
Raw Normal View History

2019-11-18 14:05:53 +01:00
/*3. Write a query to find the salesmen of the city New York who achieved the commission more than 13%.*/
/*Code to create the view*/
CREATE VIEW newyorkstaff
AS SELECT *
FROM salesman
WHERE city = 'New York';
/*Code to see the records form the view*/
SELECT *
FROM newyorkstaff
WHERE commission > .13;