1. 主键约束(Primay Key Coustraint) 唯一性,非空性 2. 外键约束 (Foreign Key Counstraint)需要建立两表间的关系并引用主表的 3. 唯一约束 (Unique Counstraint)唯一性,可以空,但只能有一个 4. 默认约束 (Default C ...
分类:
其他好文 时间:
2019-10-14 15:06:31
阅读次数:
1130
数据库索引本质上是一种数据结构(存储结构+算法),目的是为了加快数据检索速度。 1、索引的类型(待完善) 主键索引:给表设置主键,这个表就拥有主键索引。 唯一索引:unique 普通索引:增加某个字段的索引,比如用户表根据用户名查询。 组合索引:使用多个字段创建索引,遵循最左原则,比如创建索引(co ...
分类:
数据库 时间:
2019-10-13 19:01:23
阅读次数:
134
1. 查看主库的参数设置: SQL> show parameter log_archive_dest_2 NAME TYPE VALUE ------------------------------------ ----------- ------------------------------ l... ...
分类:
数据库 时间:
2019-10-13 17:13:20
阅读次数:
132
Game theory Nim SG function Graph theory SPFA Dijkstra MST (Kruskal) Virtual tree 例: "[SDOI2011]消耗战" Tree plus cycle (contaning multiple edges) Heavy ...
分类:
其他好文 时间:
2019-10-12 22:26:29
阅读次数:
95
表完整性约束 作用,用于保证数据的完整性和一致性 |约束条件|说明| | | | |primary key|标识该字段为该表的主键,可以唯一的标识记录,不可以为空| |foreing key|标识该字段为表的外键,实现表与表之间的关联| |not null|标识该字段不能为空| |unique ke ...
分类:
其他好文 时间:
2019-10-12 13:33:38
阅读次数:
123
(1)使用ALTER TABLE语句创建索引。语法如下:alter table table_name add index index_name (column_list) ; #普通索引alter table table_name add unique (column_list) ; #唯一索引al ...
分类:
其他好文 时间:
2019-10-12 01:50:46
阅读次数:
115
var maps = echarts.init(document.getElementById('map')); var option = { tooltip: { formatter: function(params) { var content = '', content = params.na... ...
分类:
其他好文 时间:
2019-10-11 15:20:29
阅读次数:
593
Given an array nums of n integers, are there elements a, b, c in nums such that a + b + c = 0? Find all unique triplets in the array which gives the s ...
分类:
其他好文 时间:
2019-10-11 10:31:45
阅读次数:
91
建虚点,点权看作是从虚点连向实点的边权. 对整个图和虚点跑最小生成树即可. ...
分类:
其他好文 时间:
2019-10-10 20:45:49
阅读次数:
107
PV、UV、VV、IP的区别 PV即Page View,网站浏览量 UV即Unique Visitor。独立访客数 VV即Visit View,访客的访问次数 IP即Internet Protocol,独立IP数 ...
分类:
其他好文 时间:
2019-10-10 16:04:31
阅读次数:
120