摘要: 举例 table1 id, 主键自增 state 状态 table2 id, 主键自增 table1Id table1的外键 name 要求:要查询所有table1状态为1对应table2中name信息第一种写法SELECT table2.nameFROM table1, tab... 阅读全文
posted @ 2015-11-20 14:44 宝贝青蛙 阅读(268) 评论(0) 推荐(0)
摘要: --随机从表中取一个Select Top 1 * From table Order By NEWID() 阅读全文
posted @ 2015-11-18 22:58 宝贝青蛙 阅读(94) 评论(0) 推荐(0)