Menu

SQLite query for display result in ascending order

Write the SQLite query for display result in ascending order(Display the age coloum as a ascending order)


  • Database Name: MyCircle, Table Name: Friends
  • |ID|Name    |Age|
    | 1 |Nitin    | 21 |
    | 2 |Kaka    | 22 |
    | 3 |Ganesh| 20 |
    | 4 |Sama    | 18 |
    | 5 |Pavan    | 16 |
    | 6 |Akash    | 10 |
    | 7 |Gopi    | 08 |
    | 8 |Rushi    | 04 |
    | 9 |Didi    | 03 |
  • select * from Friends order by Age;
  • output
    | 9 |Didi    | 03 |
    | 8 |Rushi    | 04 |
    | 7 |Gopi    | 08 |
    | 6 |Akash    | 10 |
    | 5 |Pavan    | 16 |
    | 4 |Sama    | 18 |
    | 3 |Ganesh| 20 |
    | 1 |Nitin    | 21 |
    | 2 |Kaka    | 22 |
swamios

For More Information Please Visit


No comments:

Post a Comment

Related Posts Plugin for WordPress, Blogger...