DATABASE SYSTEM CONCEPTS, SIXTH EDITION
11.1 Basic Concepts
An index for a file in a database system works in much the same way as the index
in this textbook. If we want to learn about a particular topic (specified by a word
or a phrase) in this textbook, we can search for the topic in the index at the back
of the book, find the pages where it occurs, and then read the pages to find the
information for which we are looking. The words in the index are in sorted order,
making it easy to find the word we want. Moreover, the index is much smaller
than the book, further reducing the effort needed.
Database-system indices play the same role as book indices in libraries. For
example, to retrieve a student record given an
ID
, the database system would look
up an index to find on which disk block the corresponding record resides, and
then fetch the disk block, to get the appropriate student record.
Keeping a sorted list of students’
ID
would not work well on very large
databases with thousands of students, since the index would itself be very big;
further, even though keeping the index sorted reduces the search time, finding a
student can still be rather time-consuming. Instead, more sophisticated indexing
techniques may be used. We shall discuss several of these techniques in this
chapter.
There are two basic kinds of indices:


Ordered indices. Based on a sorted ordering of the values.


Hash indices. Based on a uniform distribution of values across a range of
buckets. The bucket to which a value is assigned is determined by a function,
called a hash function.

We shall consider several techniques for both ordered indexing and hashing.
No one technique is the best. Rather, each technique is best suited to particular
database applications. Each technique must be evaluated on the basis of these
factors:


Access types: The types of access that are supported efficiently. Access types
can include finding records with a specified attribute value and finding
records whose attribute values fall in a specified range.

Access time: The time it takes to find a particular data item, or set of items,
using the technique in question.

Insertion time: The time it takes to insert a new data item. This value includes
the time it takes to find the correct place to insert the new data item, as well
as the time it takes to update the index structure.

Deletion time: The time it takes to delete a data item. This value includes
the time it takes to find the item to be deleted, as well as the time it takes to
update the index structure.

Space overhead: The additional space occupied by an index structure. Pro-
vided that the amount of additional space is moderate, it is usually worth-
while to sacrifice the space to achieve improved performance.
We often want to have more than one index for a file. For example, we may
wish to search for a book by author, by subject, or by title.
An attribute or set of attributes used to look up records in a file is called a
search key. Note that this definition of key differs from that used in primary key,
candidate key, and superkey. This duplicate meaning for key is (unfortunately) well
established in practice. Using our notion of a search key, we see that if there are
several indices on a file, there are several search keys.

Indexing and Hashing的更多相关文章

  1. 局部敏感哈希-Locality Sensitive Hashing

    局部敏感哈希 转载请注明http://blog.csdn.net/stdcoutzyx/article/details/44456679 在检索技术中,索引一直须要研究的核心技术.当下,索引技术主要分 ...

  2. 局部敏感哈希(Locality-Sensitive Hashing, LSH)方法介绍

    局部敏感哈希(Locality-Sensitive Hashing, LSH)方法介绍 本文主要介绍一种用于海量高维数据的近似近期邻高速查找技术--局部敏感哈希(Locality-Sensitive ...

  3. 局部敏感哈希(Locality-Sensitive Hashing, LSH)

    本文主要介绍一种用于海量高维数据的近似最近邻快速查找技术——局部敏感哈希(Locality-Sensitive Hashing, LSH),内容包括了LSH的原理.LSH哈希函数集.以及LSH的一些参 ...

  4. Post Tuned Hashing,PTH

    [ACM 2018] Post Tuned Hashing_A New Approach to Indexing High-dimensional Data [paper] [code] Zhendo ...

  5. 哈希学习(2)—— Hashing图像检索资源

    CVPR14 图像检索papers——图像检索 1.  Triangulation embedding and democratic aggregation for imagesearch (Oral ...

  6. 局部敏感哈希 Kernelized Locality-Sensitive Hashing Page

    Kernelized Locality-Sensitive Hashing Page   Brian Kulis (1) and Kristen Grauman (2)(1) UC Berkeley ...

  7. 局部敏感哈希(Locality-Sensitive Hashing, LSH)方法介绍(转)

    局部敏感哈希(Locality-Sensitive Hashing, LSH)方法介绍 本文主要介绍一种用于海量高维数据的近似最近邻快速查找技术——局部敏感哈希(Locality-Sensitive ...

  8. 单细胞分析实录(1): 认识Cell Hashing

    这是一个新系列 差不多是一年以前,我定导后没多久,接手了读研后的第一个课题.合作方是医院,和我对接的是一名博一的医学生,最开始两边的老师很排斥常规的单细胞文章思路,即各大类细胞分群.注释.描述,所以起 ...

  9. [Algorithm] 局部敏感哈希算法(Locality Sensitive Hashing)

    局部敏感哈希(Locality Sensitive Hashing,LSH)算法是我在前一段时间找工作时接触到的一种衡量文本相似度的算法.局部敏感哈希是近似最近邻搜索算法中最流行的一种,它有坚实的理论 ...

随机推荐

  1. http://blog.csdn.net/u010246789/article/details/52539576

    http://blog.csdn.net/u010246789/article/details/52539576

  2. Mac 自带 apache

    1.启动服务器 sudo apachectl start http://localhost   能访问就ok sudo apachectl stop sudo apachectl restart ht ...

  3. iOS之04-方法的声明和实现

    本次重点学习和理解OC对象方法的声明和定义 代码: /* 计算器类 方法: 1> 返回 π 2> 计算某个整数的平方 3> 计算两个整数的和 */ #import <Found ...

  4. 浅谈 LCA

    LCA问题 一.概述: 在图论与计算科学中,两个节点 v 与 w 在有向无环图( directed acyclic graph , DAG )或树中的最近公共祖先(Lowest common ancc ...

  5. POJ 2823 Sliding Window 题解

    POJ 2823 Sliding  Window 题解 Description An array of size n ≤ 106 is given to you. There is a sliding ...

  6. Linux 日常维护命令

    1   防火墙配置 1)重启后生效  开启: chkconfig iptables on  关闭: chkconfig iptables off 或者 /sbin/chkconfig --level  ...

  7. 【BZOJ3207】花神的嘲讽计划I 可持久化线段树/莫队

    看到题目就可以想到hash 然后很自然的联想到可持久化权值线段树 WA:base取了偶数 这道题还可以用莫队做,比线段树快一些 可持久化线段树: #include<bits/stdc++.h&g ...

  8. 编码Q&A

    Q:什么是编码? A:由于计算机中所有数据都是以二进制存在,那么为了存储数字,字母,各种符号和文字,计算机必须用一套映射系统来对应.比如我在某台计算机上规定,用00010001这个二进制数表示字母a, ...

  9. ECMAScript中关于如何获取this的定义

    文章中一些名词的翻译存疑,没有查过正式的中文名称 前面都是具体过程的解释,懒得看可以直接看获取思路 有关this的取值请移步JavaScript笔记--this的取值 获取this的过程 Runtim ...

  10. vsphere平台windows虚拟机克隆的小插曲

    问题: 1.克隆完windows虚拟化后输入法乱码. 2.开启远程的情况下远程登录输入正确的密码也无法登录. 解决: 1.更改管理员用户密码(不输入原win7密码更改win7密码). 2.重新启用管理 ...