diff --git a/lab-2/music-store-app/sql/practice_queries.sql b/lab-2/music-store-app/sql/practice_queries.sql index b1006c36236d8de7ff2cf0de01a543a8753cfb23..f2872a19d3abe2771b92fec648f3ac2ba3ea0680 100644 --- a/lab-2/music-store-app/sql/practice_queries.sql +++ b/lab-2/music-store-app/sql/practice_queries.sql @@ -1 +1,16 @@ -SELECT (name, price) FROM Album; +/* Here are some example RUD operations! +They're not all that sensible...maybe you'll +figure out why as we progress through the labs! */ + +/* Select all columns from Album table */ +SELECT * FROM Album; + +/* Selct only name and year columns from Album table +and where price > £15 */ +SELECT name, year FROM Album WHERE price > 15; + +/* Update the price of albums called 'Soul Rebel' */ +UPDATE Album SET price=21.99 WHERE name='Soul Rebel'; + +/* Delete artists with first_name Madonna (Yay!) */ +DELETE FROM Artist WHERE first_name='Madonna'; \ No newline at end of file