09 2017 档案

摘要:count(*)表示计算总行数 select count(*) from students; max(列)表示求此列的最大值 select max(id) from students where gender=0; min(列)表示求此列的最大值 select min(id) from studen 阅读全文
posted @ 2017-09-28 15:36 zy-- 阅读(187) 评论(0) 推荐(0) 编辑
摘要:vi 3 中模式: w保存 q退出 !强制 wq保存退出 x(小写) shift+zz q!不保存退出 Ctrl + n 自动补全 光标键:(命令模式) H 左 J 下 K 上 L 右 M 中间位置 L 当前屏幕的最后一行 yy 复制,8yy:表示从当前光标所在的行开始复制8行 p 粘贴 dd 剪刀 阅读全文
posted @ 2017-09-23 20:00 zy-- 阅读(137) 评论(1) 推荐(0) 编辑
摘要:在终命令行中输入,分别启动 python2 和 python3 分别用以下命令安装pip、pip3 sudo apt install python-pip sudo apt install python3-pip pip是python的包管理器 阅读全文
posted @ 2017-09-22 17:20 zy-- 阅读(1537) 评论(0) 推荐(0) 编辑
摘要:为快速得到统计数据,提供5个聚合函数 count(*)表示统计总行数 select count(*) from students; max(列)表示求此列的最大值 mix(列)表示求此列的最小值 阅读全文
posted @ 2017-09-21 16:13 zy-- 阅读(160) 评论(0) 推荐(0) 编辑
摘要:select * from 表名; 在 select 后面列前使用distinct 可以消除重复的行 select distinct gender from students; 一、条件 使用where子句对表中的数据筛选,结果为true的行会出现在结果集中 语法如下 select * from 表 阅读全文
posted @ 2017-09-19 23:38 zy-- 阅读(154) 评论(0) 推荐(0) 编辑
摘要:mysql -hip地址 -uroot -p 登录 exit = Ctrl + d 退出 select version(); 查看当前版本 select now(); 显示当前时间 create database 数据库名字 charset = utf8; 创建数据库 drop database 数 阅读全文
posted @ 2017-09-19 00:36 zy-- 阅读(176) 评论(0) 推荐(0) 编辑
摘要:转自(http://blog.csdn.net/w410589502/article/details/51767212) 本文我们主要介绍一下Navicat for Mysql 连接装在虚拟机Ubuntu上的mysql服务器时出现的问题的解决方案。 Navicat 是一套功能强大的MySQL资料库伺 阅读全文
posted @ 2017-09-18 17:00 zy-- 阅读(160) 评论(0) 推荐(0) 编辑
摘要:转自(http://www.cnblogs.com/iscodercn/p/5488633.html),有补充 一、安装mysql 1. 安装需要使用root账号,如果不会设置root账号的请自行google。安装mysql过程中,需要设置mysql的root账号的密码,不要忽略了。 2. 以上3个 阅读全文
posted @ 2017-09-18 13:25 zy-- 阅读(176) 评论(0) 推荐(0) 编辑
摘要:Ubuntu 16.04 几个国内更新源 Ubuntu 16.04 几个国内更新源 在修改source.list前,先备份一份 sudo cp /etc/apt/sources.list /etc/apt/sources.list.old 执行命令打开source.list文件 sudo vi /e 阅读全文
posted @ 2017-09-15 14:40 zy-- 阅读(525) 评论(0) 推荐(0) 编辑
摘要:恢复内容开始 Linux和Unix系统下: ifconfig 查看IP地址 ping:1 ping 192.168.109.128 测试网络连接是否正常 ssh:远程登录 ssh xxx@192.168.109.128 ssh 用户名@ip who: 查看当前登录的用户信息 who -q whoam 阅读全文
posted @ 2017-09-14 23:08 zy-- 阅读(199) 评论(0) 推荐(0) 编辑
摘要:cd ~ 跳回家目录 > 重定向 >> more |(管道) touch(新建) gedit(打开编辑) more(查看) cat(查看、合并,使用重定向) grep(筛选内心,可以使用正则) find(查找文件位置) cp a b 将a文件夹整体复制到b文件夹下 cp a/* b 将a文件下所有内 阅读全文
posted @ 2017-09-13 20:50 zy-- 阅读(157) 评论(0) 推荐(0) 编辑
摘要:常用命令: Ctrl+shift+“+”=放大 Ctrl+“-”=缩小 ls: -a 显示指定目录下所有子目录与文件,包括隐藏文件 -l 以列表方式显示文件的详细信息 -h 配合 -l 显示文件大小 cd: pwd 显示当前路径 touch 创建文件,linux没有后缀说法,所以可以不写。 ls * 阅读全文
posted @ 2017-09-12 18:27 zy-- 阅读(140) 评论(0) 推荐(0) 编辑
摘要:通过ppa安装,打开终端,输入以下命令: (PPA是Personal Package Archives首字母简写) 安装: sudo add-apt-repository ppa:webupd8team/sublime-text-3 sudo apt-get update sudo apt-get 阅读全文
posted @ 2017-09-12 13:34 zy-- 阅读(5113) 评论(0) 推荐(0) 编辑
摘要:转自(http://blog.csdn.net/Wangdada111/article/details/73382537?locationNum=2&fps=1) 安装: 测试: $python3.6 --version Python3.6.0 阅读全文
posted @ 2017-09-12 12:59 zy-- 阅读(400) 评论(1) 推荐(0) 编辑
摘要:1 brew install mysql ( 安装 ) 2 bash mysql.server start (启动) 3 mysql -uroot (登陆) mysql> show databases; 4 退出MySQL命令:exit + (回车) ************************ 阅读全文
posted @ 2017-09-11 23:57 zy-- 阅读(6612) 评论(0) 推荐(0) 编辑
摘要:这两天听浮躁,静不下来。下午看了微博上推荐的电影《最后的狮子》, 我从小就喜欢看动物世界,所以看得还算投入,现在闭上眼睛总能出现 那种黄昏的画面,草丛里探出一个脑袋和一双猎杀的眼睛。 我最深的感受来源于那头母狮,狮生所有的悲痛和残忍都发生在她身上, 未能守护家园、受伤,曾经依靠的雄狮也因衰老寡不敌众 阅读全文
posted @ 2017-09-09 00:57 zy-- 阅读(809) 评论(0) 推荐(0) 编辑
摘要:闭包函数必须有内嵌函数 内嵌函数需要引用该嵌套函数上一级变量 闭包函数必须返回内嵌函数 阅读全文
posted @ 2017-09-04 21:42 zy-- 阅读(216) 评论(0) 推荐(0) 编辑
摘要:#z装饰器import timedef deco(func): def wrapper(): startT = time.time() func() endT = time.time() msecs = (endT - startT)*1000 print("it's %f ms" % msecs) 阅读全文
posted @ 2017-09-04 17:58 zy-- 阅读(95) 评论(0) 推荐(0) 编辑
摘要:import os import sys modulepath = os.getcwd () + '\\module' sys.path.append(modulepath) 阅读全文
posted @ 2017-09-04 15:58 zy-- 阅读(162) 评论(0) 推荐(0) 编辑
摘要:*.pyc 命令:python - m py_comple file.py 脚本: import py_compile py_compile.compile('module.py' , 'module.pyc') *.pyo 或 opt 命令:python - O - m py_compile mo 阅读全文
posted @ 2017-09-04 15:39 zy-- 阅读(171) 评论(0) 推荐(0) 编辑
摘要:import 模块名字 import 模块名字 as 别名 from 模块名 import 函数/类名/ * 阅读全文
posted @ 2017-09-04 15:33 zy-- 阅读(133) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示