码迷,mamicode.com
首页 > 其他好文 > 详细

Working with Data Sources 3

时间:2016-11-18 07:30:06      阅读:171      评论:0      收藏:0      [点我收藏+]

标签:cer   contain   row   return   comm   request   res   data   this   

SQL And Database:

1.SQL query is to request the data from the database.

2.We use SELECT command to pick the specific column from the database.

  SELECT rank,major # This command will return a list which contains the data completely follow the order of column it selected. 

  FROM recent_grads;

3.Use WHERE command to select certain rows which satisfy the condition.

  SELECT Major,Employed FROM recent_grads WHERE Employed > 10000 

4.Use LIMIT to specify certain number of results.

5.Use Order by to specify the order for the rows.(desc and asc)  

6.Order by can also specify mutiple columns by orders. 

Working with Data Sources 3

标签:cer   contain   row   return   comm   request   res   data   this   

原文地址:http://www.cnblogs.com/kingoscar/p/6076169.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!