- 博客(7)
- 收藏
- 关注
原创 mysql里查询时按自定义字符串顺序排序
SELECT t.pointtype,COUNT(1) FROM `test` t GROUP BY t.pointtype ORDER BY case when t.pointtype='aa' then '1' when t.pointtype='bb' then '2' when t.pointtype='cc' then '3' when t.pointtype='dd' then '4' else t.pointtype end asc 只能排序1到9. select*fromt_...
2021-03-15 16:04:58
356
原创 计算 停电时长
表id VARCHAR2(256) 用户id time VARCHAR2(256) 时间 flag VARCHAR2(256) 0来电,1停电 计算 停电时长,使用了 lead函数 select t1.id,t1.time,t1.flag,t1.next_time from (select t.id id,t.time,t.flag, lead(t.time, 1, null) over(partition by t.id order by t.id) ne...
2020-10-27 18:22:13
558
原创 ubuntu下安装chrome
第一步:下载.deb包 32位 $wget https://dl.google.com/linux/direct/google-chrome-stable_current_i386.deb 64bit $wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb 第二步:下载好之后安装 ...
2019-01-24 11:09:41
1206
转载 xshell-常用命令
转载自:https://blog.csdn.net/jay8824589/article/details/52037032 suse linux 常用命令 运行jar包 java -jar ****.jar (1)命令ls——列出文件 ls -la 给出当前目录下所有文件的一个长列表,包括以句点开头的“隐藏”文件 ls a* 列出当前目录下以字母a开头的所有文件 ls -l *.do...
2019-01-17 18:11:52
197
原创 java中list去除重复项
List<String> list= new ArrayList<>(); list= list.stream().distinct().collect(Collectors.toList());
2019-01-07 17:42:11
497
转载 计算某行代码运行时间
long start = System.currentTimeMillis(); ----------代码行------------ long end = System.currentTimeMillis(); System.out.println(href); System.out.println("运行时间:" + (end - start) + "毫秒"); ...
2018-12-14 17:48:17
1135
转载 java代码调用http接口
整合了两种请求方式,特此写下来供日后使用。 //通过get请求 public void get() { try { URL thisurl = new URL(URL); // 把字符串转换为URL请求地址 HttpURLConnection connection = (HttpURLConnection) thisurl ...
2018-12-14 16:11:34
998
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人