码迷,mamicode.com
首页 >  
搜索关键字:where    ( 20257个结果
MySql 查询一周内最近7天记录
本周内:select * from wap_content where week(created_at) = week(now)查询一天:select * from table where to_days(column_time) = to_days(now());select * from tab...
分类:数据库   时间:2015-10-09 11:55:06    阅读次数:750
Laravel数据库操作
laravel数据库有三种访问方式一、基本Facade用法注意,首先要引入:use Illuminate\Support\Facades\DB; 不然报错DB' not found返回的是数组对象:$results = DB::select('select * from users where id...
分类:数据库   时间:2015-10-09 00:34:27    阅读次数:253
mysql基础
select 语句select语句可以从一个或者多个表中选取特定的行和列,结果通常是生成一个临时表。在执行过程中系统根据用户的标准从数据库中选出匹配的行和列,并将结果放到一个临时的表中,这就是实现选择和投影运算的一个形式。语法格式select ****from 子句where 子句group BY ...
分类:数据库   时间:2015-10-09 00:30:12    阅读次数:295
宿迁用户去往外地分析
数据抽取 将几张表中的数据放到一张表中 ????select?s_cycle_date?as?f_date,roam_prov_id,mdn,mdn_city_id?into?tmp_qgj_sqmy?from?mpm00005?where?roam_prov_id<>1?and?mdn_city_id=9 ???i...
分类:其他好文   时间:2015-10-08 23:19:30    阅读次数:379
[LeetCode]Valid Sudoku
题目描述:(链接)Determine if a Sudoku is valid, according to:Sudoku Puzzles - The Rules.The Sudoku board could be partially filled, where empty cells are fil...
分类:其他好文   时间:2015-10-08 22:52:18    阅读次数:163
84. Largest Rectangle in Histogram (Array; Stack, DP)
Givennnon-negative integers representing the histogram's bar height where the width of each bar is 1, find the area of largest rectangle in the histog...
分类:其他好文   时间:2015-10-08 21:27:26    阅读次数:186
mysql查询区分大小写
Mysql默认查询是不分大小写的,可以在SQL语句中加入binary来区分大小写。binary不是函数,是类型转换运算符,它用来强制它后面的字符串为一个二进制字符串,可以理解为在字符串比较的时候区分大小写。SELECT * FROM t_resource_info WHERE binary RESO...
分类:数据库   时间:2015-10-08 20:01:20    阅读次数:220
马哥linux笔记 第一天
第一天内容:1、上课环境准备2、计算机及操作系统基础知识3、计算机及操作系统基础知识24、linux系统安装及初步认识一、写博客要求:5w1h(what,why,who,where,when,how)条理清晰,合适编排,用户体验二、计算机五大部件CPU(运算器+控制器)、Memory(存储器)、I/O(输入、输出设备..
分类:系统相关   时间:2015-10-08 18:26:57    阅读次数:255
ThinkPHP中getField( )和field( )
做数据库查询的时候,比较经常用到这两个,总是查手册,记不住,现在把它总结下,希望以后用的时候不查手册了。不管是用select 查询数据集,还是用find 查询数据,常配合连贯操作where、field、order等一起使用。field():用于定义要查询的字段(支持字段排除)用法:field($fi...
分类:Web程序   时间:2015-10-08 16:36:17    阅读次数:151
134. Gas Station (Array; DP)
There are N gas stations along a circular route, where the amount of gas at station i is gas[i].You have a car with an unlimited gas tank and it costs...
分类:其他好文   时间:2015-10-08 16:15:38    阅读次数:124
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!