MySql-Mysql技术内幕~SQL编程学习笔记(N)
1、_rowid
类似Oracle的rowid
mysql> select _rowid rowid,t.* from city t limit ;
+-------+----+----------------+-------------+---------------+------------+
| rowid | ID | Name | CountryCode | District | Population |
+-------+----+----------------+-------------+---------------+------------+
| | | Kabul | AFG | Kabol | |
| | | Qandahar | AFG | Qandahar | |
| | | Herat | AFG | Herat | |
| | | Mazar-e-Sharif | AFG | Balkh | |
| | | Amsterdam | NLD | Noord-Holland | |
| | | Rotterdam | NLD | Zuid-Holland | |
| | | Haag | NLD | Zuid-Holland | |
| | | Utrecht | NLD | Utrecht | |
| | | Eindhoven | NLD | Noord-Brabant | |
| | | Tilburg | NLD | Noord-Brabant | |
+-------+----+----------------+-------------+---------------+------------+
rows in set (0.00 sec) mysql>
2、查看表结构
mysql> show create table t\G;
*************************** . row ***************************
Table: t
Create Table: CREATE TABLE `t` (
`a` int() unsigned DEFAULT NULL,
`b` int() unsigned DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8
row in set (0.00 sec) ERROR:
No query specified mysql> desc t;
+-------+------------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+-------+------------------+------+-----+---------+-------+
| a | int() unsigned | YES | | NULL | |
| b | int() unsigned | YES | | NULL | |
+-------+------------------+------+-----+---------+-------+
rows in set (0.00 sec) mysql>
3、hex函数
4、SQL_MODE:SQL模式
5、MySQL中的函数
1》cast:强制转换
2》
MySql-Mysql技术内幕~SQL编程学习笔记(N)的更多相关文章
- MySql-Mysql技术内幕~SQL编程学习笔记(1)
1.MySQL的历史,一些相关概念. 2.MySQL数据类型 *通常一个页内可以存放尽可能多的行,那么数据库的性能就越好,选择一个正确的数据类型至关重要. 1>UNSIGNED类型: 将数字类型 ...
- 《MySQL技术内幕——SQL编程》读书笔记(二)——数据类型
对数据类型的选择将影响与数据库交互的应用程序的性能. 1.通常来说,如果一个页内可以存放尽可能多的行,那么数据库的性能就越好,因此选择一个正确的数据类型至关重要. 2.另一方面,如果在数据库中创建表时 ...
- postgreSQL PL/SQL编程学习笔记(六)——杂七杂八
1 PL/pgSQL Under the Hood This part discusses some implementation details that are frequently import ...
- postgreSQL PL/SQL编程学习笔记(三)——游标(Cursors)
Cursors Rather than executing a whole query at once, it is possible to set up a cursor that encapsul ...
- postgreSQL PL/SQL编程学习笔记(二)
Control Structures of PL/SQL Control structures are probably the most useful (and important) part of ...
- postgreSQL PL/SQL编程学习笔记(一)
1.Structure of PL/pgSQL The structure of PL/pgSQL is like below: [ <<label>> ] [ DECLARE ...
- postgreSQL PL/SQL编程学习笔记(五)——触发器(Triggers)
Trigger Procedures PL/pgSQL can be used to define trigger procedures on data changes or database eve ...
- postgreSQL PL/SQL编程学习笔记(四)
Errors and Messages 1. Reporting Errors and Messages Use the RAISE statement to report messages and ...
- MySQL基础之事务编程学习笔记
MySQL基础之事务编程学习笔记 在学习<MySQL技术内幕:SQL编程>一书,并做了笔记.本博客内容是自己学了<MySQL技术内幕:SQL编程>事务编程一章之后,根据自己的理 ...
随机推荐
- jQuery2.0.3源码
概览 整体结构 (function (){ (21 , 94) 定义了一些变量和函数 jQuery=function(); (96 , 293) 给jQuery对象添加一些方法和属性; (285 ...
- 【SpringBoot】spring-session-data-redis 解决集群环境下session共享
为什么会产生Session共享问题 集群情况下,session保存在各自的服务器的tomcat中,当分发地址至不同服务时,导致sesson取不到,就会产生session共享问题. 解决方案 负载均 ...
- anaconda历史版本下载
anaconda历史版本安装: anaconda所有版本链接:https://repo.continuum.io/archive/ 清华大学开源软件镜像站:https://mirrors.tuna.t ...
- shiro框架学习-9-shiroSession
1.什么是会话session : 用户和程序直接的链接,程序可以根据session识别到哪个用户,和javaweb中的session类似 2. 什么是会话管理器SessionManager : 会话管 ...
- python导入包失败ModuleNotFoundError: No module named 'matplotlib.pyplot'; 'matplotlib' is not a package
最近在看 python,在使用matplotlib进行绘图时,提示:ModuleNotFoundError: No module named 'matplotlib.pyplot'; 'matplot ...
- python Tkinter 组件
Tkinter的提供各种控件,如按钮,标签和文本框,一个GUI应用程序中使用.这些控件通常被称为控件或者部件. 目前有15种Tkinter的部件.我们提出这些部件以及一个简短的介绍,在下面的表: 控件 ...
- Django之nginx+wsgi后台部署(最新版)
0-部署准备 1.要使用安全组打开腾讯云的80端口 腾讯云的80端口不能访问www.jianshu.com 以实际项目部署为例 项目名称api_learn: Python版本:python 3.6. ...
- POJ 3660 Cow Contest 任意两点之间的关系 Floyd
题意:牛之间有绝对的强弱,给出一些胜负关系,问有多少头牛可以确定其绝对排名. #include <iostream> #include <cstdio> #include &l ...
- HY中考游记
回首三年荏苒,还是有许多忘不了,有始有终,最后以一篇游记来记录落幕吧 Day -inf 为了准备中考从机(颓)房回到学校了,停课这么久,也该好好备考了 希望能回到以前的文化课水平QAQ Day -? ...
- 官方转译:截止2018-12-10,chromedriver与chrome对应关系表
谷歌驱动下载地址: http://npm.taobao.org/mirrors/chromedriver/ http://chromedriver.storage.googleapis.com/ind ...