码迷,mamicode.com
首页 >  
搜索关键字:where    ( 20257个结果
sql中常量和变量的引用
String name =jtf.getText().trim();String sql="select * from stu where stuname=' "+name+" ' ";'"+name+"'这样表示你数据库里的字段不是数字或者自动编号型的"+name+"这样表示数字或者自动编号型如果...
分类:数据库   时间:2015-04-18 14:22:46    阅读次数:302
LBS优化方案探究
方案1:假设数据结构是这个样子的结构那么找某个范围之内的用户,相当于:select * from tb_lbs_user where lat > lat_min and lat lng_min and lng 示例:key value5cfr5x {{12322:{11,11,1}},{1234:....
分类:其他好文   时间:2015-04-18 13:03:30    阅读次数:203
sql有几种删除表数据的方式
有几种删除表数据的方式?truncate、delete和drop都可以删除数据。TRUNCATE TABLE删除表中的所有行,而不记录单个行删除操作。TRUNCATE TABLE 与没有 WHERE 子句的 DELETE 语句类似;但是,TRUNCATE TABLE 速度更快,使用的系统资源和事务日...
分类:数据库   时间:2015-04-18 12:50:52    阅读次数:193
142. Linked List Cycle II
Given a linked list, return the node where the cycle begins. If there is no cycle, returnnull.Follow up:Can you solve it without using extra space?Cra...
分类:其他好文   时间:2015-04-18 08:40:30    阅读次数:106
Bitwise AND of Numbers Range
题目:Given a range [m, n] where 0 >>= 1; 8 n >>>= 1; 9 count++;10 }11 return m <<= count;12 }
分类:其他好文   时间:2015-04-18 08:40:02    阅读次数:104
42. Trapping Rain Water
题目:Givennnon-negative integers representing an elevation map where the width of each bar is 1, compute how much water it is able to trap after raining...
分类:移动开发   时间:2015-04-17 23:51:07    阅读次数:163
【LeetCode】201. Bitwise AND of Numbers Range
Bitwise AND of Numbers RangeGiven a range [m, n] where 0 = (int)pow(2.0, i)) && (ind+gap <= (int)pow(2.0, i+1)-1)) //all 1's ...
分类:其他好文   时间:2015-04-17 23:38:37    阅读次数:138
数据库设主键以及where的应用
二、第二课createtableteacher(tnointprimarykeyidentity(1,1),--将tno设为主键(primarykeyidentity(1,1))tnamevarchar(50))goinsertintoteachervalues('张三')insertintotea...
分类:数据库   时间:2015-04-17 19:58:34    阅读次数:215
SQL语句学习
看似简单,但其实包含很多技巧思维1.查询课程表中所有科目大于80的学生select distinct name from student where name not in (select name from student where grade=80);这样代表只要有一门大于80即可
分类:数据库   时间:2015-04-17 19:50:36    阅读次数:153
SQL必知必会 笔记 第十八章 使用视图
18.1视图视图是虚拟的表。与包含数据的表不一样,试图只包含使用时动态检索数据的查询。 可将整个查询包装成一个名为ProductCustomers的虚拟表,则可以如下轻松地检索出相同的数据。SELECT cust_name,cust_contact FROM ProductCustomers WHERE prod_id = 'RGAN01';ProductCustomers是一个视图,作为视图,他...
分类:数据库   时间:2015-04-17 18:17:40    阅读次数:157
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!