
mysql
文章平均质量分 84
page_qiu
这个作者很懒,什么都没留下…
展开
-
20.2 Document Store Concepts
This section explains the concepts introduced as part of using MySQL as a document store.本节解释了将MySQL用作文档存储时引入的概念。 JSON Document Collection CRUD Operations JSON DocumentA JSON document is a data structure composed of key-value pairs and i翻译 2022-03-10 16:43:01 · 130 阅读 · 0 评论 -
13.5 Prepared Statements
MySQL 8.0 provides support for server-side prepared statements. This support takes advantage of the efficient client/server binary protocol. Using prepared statements with placeholders for parameter values has the following benefits:MySQL 8.0支持服务器端prepar翻译 2022-02-17 11:32:56 · 301 阅读 · 0 评论 -
20.4.1 MySQL Shell
This quick-start guide assumes a certain level of familiarity with MySQL Shell. The following section is a high level overview, see the MySQL Shell documentation for more information. MySQL Shell is a unified scripting interface to MySQL Server. It support翻译 2021-12-21 23:20:21 · 263 阅读 · 0 评论 -
8.8.1 Optimizing Queries with EXPLAIN
TheEXPLAINstatement provides information about how MySQL executes statements:EXPLAIN语句提供有关MySQL如何执行语句的信息: EXPLAINworks withSELECT,DELETE,INSERT,REPLACE, andUPDATEstatements. EXPLAIN与SELECT、DELETE、INSERT、REPLACE和UPDATE语句一起协作 WhenEXP...翻译 2021-12-08 23:02:03 · 104 阅读 · 0 评论 -
14.2 Transactional JDBC Access
Spring allows us to add transactions into our code without having to deal directly with the JDBC classes. For that purpose, Spring provides a transaction management package that not only replaces JDBC transaction management, but also enables declarative tr翻译 2021-12-01 23:12:56 · 203 阅读 · 0 评论 -
8.2.1.3 Index Merge Optimization
TheIndex Mergeaccess method retrieves rows with multiplerangescans and merges their results into one. This access method merges index scans from a single table only, not scans across multiple tables. The merge can produce unions, intersections, or unio...翻译 2021-09-30 11:45:07 · 136 阅读 · 0 评论 -
8.2.1.1 WHERE Clause Optimization
This section discusses optimizations that can be made for processingWHEREclauses. The examples useSELECTstatements, but the same optimizations apply forWHEREclauses inDELETEandUPDATEstatements.本篇讨论关于WHERE从句优化方面的内容,虽然例子是用SELECT 语句,但是这个优化同样适用于DEL...翻译 2021-09-13 20:32:36 · 175 阅读 · 0 评论 -
8.3.14 Indexed Lookups from TIMESTAMP Columns
Temporal values are stored inTIMESTAMPcolumns as UTC values, and values inserted into and retrieved fromTIMESTAMPcolumns are converted between the session time zone and UTC. (This is the same type of conversion performed by theCONVERT_TZ()function. I...翻译 2021-09-07 20:59:59 · 115 阅读 · 0 评论 -
8.3.13 Descending Indexes
MySQL supports descending indexes:DESCin an index definition is no longer ignored but causes storage of key values in descending order. Previously, indexes could be scanned in reverse order but at a performance penalty. A descending index can be scanned ..翻译 2021-09-03 11:45:59 · 192 阅读 · 0 评论 -
8.3.12 Invisible Indexes
MySQL supports invisible indexes; that is, indexes that are not used by the optimizer. The feature applies to indexes other than primary keys (either explicit or implicit).Indexes are visible by default. To control visibility explicitly for a new index,翻译 2021-08-30 17:50:54 · 278 阅读 · 0 评论 -
8.3.11 Optimizer Use of Generated Column Indexes
MySQL supports indexes on generated columns. For example:MySQL支撑在如下的列上建立索引:CREATE TABLE t1 (f1 INT, gc INT AS (f1 + 1) STORED, INDEX (gc));The generated column,gc, is defined as the expressionf1 + 1. The column is also indexed and the optimizer ca..翻译 2021-08-27 17:48:25 · 206 阅读 · 0 评论 -
8.3.10 Use of Index Extensions
InnoDBautomatically extends each secondary index by appending the primary key columns to it. Consider this table definition:InnoDB通过自动在每个二级索引后面跟上主键列,比如下面这张表CREATE TABLE t1 ( i1 INT NOT NULL DEFAULT 0, i2 INT NOT NULL DEFAULT 0, d DATE DEFAULT N.翻译 2021-08-22 22:17:07 · 161 阅读 · 0 评论 -
8.3.9 Comparison of B-Tree and Hash Indexes
Storage engines collect statistics about tables for use by the optimizer. Table statistics are based on value groups, where a value group is a set of rows with the same key prefix value. For optimizer purposes, an important statistic is the average value g翻译 2021-08-22 21:26:38 · 131 阅读 · 0 评论 -
8.3.6 Multiple-Column Indexes
MySQL can create composite indexes (that is, indexes on multiple columns). An index may consist of up to 16 columns. For certain data types, you can index a prefix of the column (seeSection8.3.5, “Column Indexes”).MySQL can use multiple-column indexes ..翻译 2021-08-16 17:16:55 · 143 阅读 · 0 评论 -
8.3.5 Column Indexes
The most common type of index involves a single column, storing copies of the values from that column in a data structure, allowing fast lookups for the rows with the corresponding column values. The B-tree data structure lets the index quickly find a spec翻译 2021-08-15 21:00:41 · 168 阅读 · 0 评论 -
8.3.4 Foreign Key Optimization
If a table has many columns, and you query many different combinations of columns, it might be efficient to split the less-frequently used data into separate tables with a few columns each, and relate them back to the main table by duplicating the numeric翻译 2021-08-09 21:27:11 · 112 阅读 · 0 评论 -
8.3.3 SPATIAL Index Optimization
MySQL permits creation ofSPATIALindexes onNOT NULLgeometry-valued columns (seeSection11.4.10, “Creating Spatial Indexes”). The optimizer checks theSRIDattribute for indexed columns to determine which spatial reference system (SRS) to use for compar...翻译 2021-08-08 18:02:51 · 116 阅读 · 0 评论 -
8.3.2 Primary Key Optimization
The primary key for a table represents the column or set of columns that you use in your most vital queries. It has an associated index, for fast query performance. Query performance benefits from theNOT NULLoptimization, because it cannot include anyNU...翻译 2021-08-08 16:40:28 · 92 阅读 · 0 评论 -
mysql unsign问题
在mysql中有mysql自己的特别之处,可以设置sql_model:STRICT_TRANS_TABLES, 此时数据类型int、decimal 的unsign标志就会起到校验作用,当为负值时,就会报错,错误码: 1264 ,内容:Out of range value for column 'num' at row 1。设置sql_model模式请见网上其他博客。...原创 2019-02-02 15:23:16 · 663 阅读 · 0 评论