CBSE · 083Class XII · 2025Section D1 mark
Question 34i
4 March 2025 · Computer Science (083)
Assume that you are working in the IT Department of a Creative Art Gallery (CAG), which sells different forms of art creations like Paintings, Sculptures etc. The data of Art Creations and Artists are kept in tables Articles and Artists respectively. Following are few records from these two tables: Articles table:
| Code | A_Code | Article | DOC | Price |
|---|---|---|---|---|
| PL001 | A0001 | Painting | 2018-10-19 | 20000 |
| SC028 | A0004 | Sculpture | 2021-01-15 | 16000 |
| QL005 | A0003 | Quilling | 2024-04-24 | 3000 |
Artists table:
| A_Code | Name | Phone | DOB | |
|---|---|---|---|---|
| A0001 | Roy | 595923 | r@CrAG.com | 1986-10-12 |
| A0002 | Ghosh | 1122334 | ghosh@CrAG.com | 1972-02-05 |
| A0003 | Gargi | 121212 | Gargi@CrAG.com | 1996-03-22 |
| A0004 | Mustafa | 33333333 | Mf@CrAg.com | 2000-01-01 |
As an employee of CAG, you are required to write the SQL queries for the following : (i) To display all the records from the Articles table in descending order of price.
Answer
SELECT * FROM Articles ORDER BY Price DESC;
Explanation
Sorts all records by Price high to low.