An informational constraint is a constraint attribute that can be used by the SQL compiler to improve the access to data. Informational constraints are not enforced by the database manager, and are not used for additional verification of data; rather, they are used to improve query performance.

You define informational constraints by using the CREATE TABLE or ALTER TABLE statement. You first add constraints and then associate them with constraint attributes, specifying whether the database manager is to enforce the constraints. For primary key constraints, unique constraints, and check constraints, you can further specify that the constraint can be trusted. For referential integrity constraints, if the constraint is not enforced, you can further specify whether the constraint can be trusted. A not-enforced and not-trusted constraint is also known as a statistical referential integrity constraint. You can specify whether a referential integrity constraint or check constraint is to be used for query optimization.

Informational RI (referential integrity) constraints are used to optimize query performance, the incremental processing of REFRESH IMMEDIATE MQT, and staging tables. Query results, MQT data, and staging tables might be incorrect if informational constraints are violated.

For example, the order in which parent-child tables are maintained is important. When you want to add rows to a parent-child table, you must insert rows into the parent table first. To remove rows from a parent-child table, you must delete rows from the child table first. This ensures that there are no orphan rows in the child table at any time. Otherwise the informational constraint violation might affect the correctness of queries being executed during table maintenance, as well as the correctness of the incremental maintenance of dependent MQT data and staging tables.

You can create a not-enforced primary key or unique constraint for either a column-organized or row-organized table. Unlike an enforced primary key or unique constraint, a not-enforced primary key or unique constraint does not create an index on the data. Specify an informational constraint only if the table data is independently known to conform to the constraint. Because the DB2® database manager does not enforce uniqueness for these constraints, if the table data violates the not-enforced constraint, incorrect results can occur. You cannot reference not-enforced primary key constraints in any enforced referential integrity definitions.

复制Informational constraints on LUW DB2 v105的更多相关文章

  1. DB2许可证文件

    与 DB2® 数据库产品相关联的许可证文件有两种类型: 基本许可证密钥和 完整许可证密钥.这些许可证密钥以纯文本格式存储,通常称为 许可证文件或 许可证权利证书. "基本"许可证未 ...

  2. DB2在渗透中的应用(转载)

    原文地址:http://drops.wooyun.org/tips/16673 0x00 DB2简介 DB2是IBM公司推出关系型数据库管理系统. 现今DB2主要包含以下三个系列: DB2 for L ...

  3. goldengate 参数之GETTRUNCATES | IGNORETRUNCATES --转载

    GETTRUNCATES | IGNORETRUNCATESValid ForExtract and ReplicatDescriptionUse the GETTRUNCATESand IGNORE ...

  4. Oracle GoldenGate 19.1新特性

    1.GoldenGate 19.1 新特性概览a.支持Oracle数据库19.1 长期支持发布版本.集成Oracle GoldenGate 12.3版的最终补丁集更新.b.微服务的安全性和可管理性增强 ...

  5. MySQL 高可用架构之MMM

    简介 MMM(Master-Master replication manager for MySQL)是一套支持双主故障切换和双主日常管理的脚本程序.MMM使用Perl语言开发,主要用来监控和管理My ...

  6. mysql 主从复制 实践

    异步主从复制   主从部署步骤: 备份还原 使用mysqldump或者xtrabackup 把主库现有基础数据还原到从库 授权 grant replication slave on *.* 给从库一个 ...

  7. OGG-01008 Extract displays Discarding bad record (discard recs=1) when using filter or where clause

    因为在extract參数文件里使用了where语句,而where后面的的条件列又不是主键,没有为update.delete操作记录日志,因此会报1008错误. Applies to: Oracle G ...

  8. Oracle Data Guard配置

    Oracle Data Guard 的配置在网上有很多资料,但是没有一个完整的,配置下来多少有些问题.在踩了各种坑之后,自己终于配置成功,就想把这过程记录下来. 1   测试环境 主数据库:windo ...

  9. MySQL高可用架构-MMM安装教程

    安装指南: 一.架构以及服务器信息 基本安装包含至少2个数据库服务器和1个监视服务器.本例中使用2个监视服务器和5个数据库服务器(服务器系统为CentOS 7) 用途 IP 主机名 Server-id ...

随机推荐

  1. .NET Core Preview

    .NET Core Preview 这是很容易上手使用.NET Core在您选择的平台上. 你只需要一个命令行,一个文本编辑器和10分钟的时间. 原文链接:https://www.microsoft. ...

  2. Java Annotation自定义注解详解

    在开发过程中总能用到注解,但是从来没有自己定义过注解.最近赋闲在家,研究整理了一番,力求知其然知其所以然. 本文会尝试描述什么是注解,以及通过一个Demo来说明如何在程序中自定义注解.Demo没有实际 ...

  3. 笔记(一):ES6所改良的javascript“缺陷”

    ES6笔记(一):ES6所改良的javascript“缺陷”   块级作用域 ES5没有块级作用域,只有全局作用域和函数作用域,由于这一点,变量的作用域甚广,所以一进入函数就要马上将它创建出来.这就造 ...

  4. 在linux下安装Python:

    # 下载最新版本 cd /usr/local/src/ sudo wget http://www.python.org/ftp/python/3.3.2/Python-3.3.2.tar.bz2 su ...

  5. eclipse添加velocity项目

    1.首先添加jar包,记得包含以下的主要两个类别 2.新建一个servlet类(继承自VelocityViewServlet) package com.servlet; import java.uti ...

  6. mac 搭建APK反编译环境[转]

    APKtool 用途:获取mainifest.xml res等资源文件 下载:http://ibotpeaches.github.io/Apktool/install/ 使用:apktool d te ...

  7. 2-python学习——hello world

    "hello world"是编程界一个经久不衰的例子,几乎所有语言的学习教程都把它当做第一个程序的范例.学习的过程就是再造轮子的过程,千万不要以为有人做过的,就不去学习了. hel ...

  8. PHP 面向对象:抽象类继承抽象类

    抽象类继承另外一个抽象类时,不用重写其中的抽象方法.抽象类中,不能重写抽象父类的抽象方法.这样的用法,可以理解为对抽象类的扩展. 下面的例子,演示了一个抽象类继承自另外一个抽象类时,不需要重写其中的抽 ...

  9. Angularjs与bootstrap.datetimepicker结合实现日期选择器

    http://www.lovelucy.info/angularjs-best-practices.html http://damoqiongqiu.iteye.com/blog/1917971 ht ...

  10. display:inline 遇上 li 无效? why?

    若制作导航栏时,使用列表li 的定义时,若想加上一个背景图 ,这时候若定义li的一个属性为:li{display:inline ; width:83px; height:30px;},则浏览器会无视后 ...