oracle中dbms

Relational calculus uses variable, the formula for state and it has the same expressive power. There is two type of Relational calculus:

关系演算使用变量,状态公式,并且具有相同的表达能力关系演算有两种类型:

  1. Tuple relational calculus

    元组关系演算

  2. Domain relational calculus

    领域关系演算

1)元组关系演算 (1) Tuple relational calculus)

It is also known as predicate calculus. Tuple (t) variable range for all tuple of relation or table (R).

它也称为谓词演算。 关系或表(R)的所有元组的元组(t)可变范围。

t.A --> Column ‘A’ of tuple ‘t’

tA->元组't'的列'A'

Basic form: { T | P ( T ) } where, T is variable and P(T) is formula to fetch true tuple.

基本形式:{T | P(T)} ,其中T是变量,而P(T)是提取真实元组的公式。

Like: { t.A1, t.A2 … t.Ai | θ }

像:{t.A1,t.A2…t.Ai | θ}

where, t.A1, t.A2 ... t.Ai is predicate calculus expression and θ is condition.

其中, t.A1,t.A2 ... t.Ai是谓词演算表达式,θ是条件。

Let, we have a table name Student [ R.No, Name, D.No, Gender ]

让我们有一个表名Student [R.No,Name,D.No,Gender]

Example: - Find R.No and Name of all student in D.No is 2.

示例:-查找R.No,D.No中所有学生的姓名为2。

{ t.R.No, t.Name | t ϵ Student (Student(t)) ^ t.D.N0 = 2 }

{tRNo,t.Name | t ϵ学生(学生(t))^ tDN0 = 2}

Relational calculus uses variables, constant, comparison operators ( ==, >, =, <=, != ), logical operators (˅ , ˄) and quantifiers ( Ǝ, ᵿ ).

关系演算使用变量,常量,比较运算符(==,>,=,<=,!=),逻辑运算符(˅,˄)和量词(Ǝ,ᵿ)。

Quantifier:

量词:

Condition is expressed by use quantifier with a tuple variable. Two type of quantifiers is there Ǝ (there exists), ᵿ (for all) .

条件是通过使用带元组变量的量词来表示的。 (存在)有两种类型的量词,(全部)。

Like: -

喜欢: -

  • Ǝt (variable) -> R(θ(t)) (relation and condition)

    Ǝt(变量)-> R(θ(t))(关系和条件)

  • ᵿt (variable) -> R(θ(t)) (relation and condition)

    ᵿt(变量)-> R(θ(t))(关系和条件)

  1. there exists a tuple in ‘t’ (set of tuple) in relation ‘R’ such that ‘θ’ predicate condition is true.

    关系“ R”中的“ t”(元组集合)中存在一个元组,使得“θ”谓词条件为真。

  2. Θ(t) is true for all tuple in ‘t’ in relation ‘R’.

    对于关系“ R”中“ t”中的所有元组,Θ(t)是正确的。

Variable uses: Free tuple (no quantifier use), use quantifier in bound expression.

变量使用:自由元组(不使用量词),在绑定表达式中使用量词。

Example: List all the employee name who have no manager.

示例:列出所有没有经理的员工姓名。

{ t.name | t ϵ emp ( Ǝ emp) ˄ manager = ‘NULL’ }

{t.name | t ϵ emp(Ǝemp)˄管理器='NULL'}

2)领域关系演算 (2) Domain relational calculus)

Domain (d (attribute)) variable range for all domain (columns) of relation or table (R). It is similar work on all the domains (columns) as tuple relational calculus work for all row.

关系或表(R)的所有域(列)的域(d(属性))变量范围。 它在所有域(列)上都是类似的工作,就像元组关系演算在所有行上一样。

Basic form: { D | P ( D ) } where, D is variable and P(D) is formula to fetch true domain.

基本形式:{D | P(D)} ,其中D是变量,P(D)是获取真实域的公式。

Like: { d.A1, d.A2 … d.Ai | θ }

像:{d.A1,d.A2…d.Ai | θ}

where, d.A1, d.A2 ... d.Ai is domain calculus expression and θ is condition.

其中, d.A1,d.A2 ... d.Ai是域演算表达式,θ是条件。

Let, we have a table name Student [ R.No, Name, D.No, gender ]

让我们有一个表名Student [R.No,Name,D.No,female]

Example: - Find R.No and Name of all student in D.No is 2.

示例:-查找R.No,D.No中所有学生的姓名为2。

{ d.R.No, d.Name, d.D.No, d.gender | d ϵ Student (Student(d)) ^ d.D.N0 = 2 }

{dRNo,d.Name,dDNo,d.gender | d ϵ学生(学生(d))^ dDN0 = 2}

Conclusion

结论

In this article, we have learned about what is relation calculus and its different types with example? I hope you all clear the concept. Stay tuned for the next article, we will discuss more it in the upcoming articles. Have a nice day! Happy Learning!

在本文中,我们通过示例了解了什么是关系演算及其不同类型? 希望大家都明白这个概念。 请继续关注下一篇文章,我们将在以后的文章中讨论更多内容。 祝你今天愉快! 学习愉快!

翻译自: https://www.includehelp.com/dbms/relational-calculus.aspx

oracle中dbms

oracle中dbms_DBMS中的关系演算相关推荐

  1. oracle中dbms_DBMS中的功能依赖性和属性关闭

    oracle中dbms 功能依赖 (Functional Dependency) A relational Database management System (RDBMS) represents ...

  2. oracle中dbms_DBMS中的实例和架构

    oracle中dbms 1)实例 (1) Instances) What is the Instance? If we look towards it in real life, we refer i ...

  3. Oracle EBS R12 运行adadmin 安装中文语言包过程中意外中断后的处理

    介绍Oracle EBS R12 运行adadmin 安装中文语言包过程中意外中断后的处. Oracle EBS R12 运行adadmin 安装中文语言包过程中意外中断或关机后,重新开机,运行数据库 ...

  4. oracle 求A中不存在于B的记录

    oracle 求A中不存在于B的记录 select * from a minus select * from b  是求A中不存在于B的记录 select * from a union select ...

  5. oracle数据库有哪些文件构成,Oracle数据库架构中包括几层?每层都有什么元素?...

    Oracle数据库架构中包括几层?每层都有 什么元素? 1 PL/SQL代表 A PROCEDURAL LANGUAGE/SQL B PROGRAM LANGUAGE SQL C POWER LANG ...

  6. rowbounds分页oracle,Oracle使用MyBatis中RowBounds实现分页查询功能

    Oracle中分页查询因为存在伪列rownum,sql语句写起来较为复杂,现在介绍一种通过使用MyBatis中的RowBounds进行分页查询,非常方便. 使用MyBatis中的RowBounds进行 ...

  7. oracle sql语句中包含‘’ 的解决方法

    oracle sql语句中包含'&' 的解决方法 参考文章: (1)oracle sql语句中包含'&' 的解决方法 (2)https://www.cnblogs.com/hm1990 ...

  8. oracle返回表id,在Oracle的函数中,返回表类型的语句

    Oracle的function中怎么返回表变量? 太晚了,过多的理论知识就不说了,下面简单地说实现吧!.. 1.创建表对象类型. 在Oracle中想要返回表对象,必须自定义一个表类型,如下所示: 复制 ...

  9. oracle set feedback off,Oracle数据库之Oracle导出数据中的prompt,set feedback 等是什么意思...

    本文主要向大家介绍了Oracle数据库之Oracle导出数据中的prompt,set feedback 等是什么意思,通过具体的内容向大家展现,希望对大家学习Oracle数据库有所帮助. mpt 输出 ...

最新文章

  1. lists,tuples and sets of Python
  2. Java源码下载和阅读(JDK1.8/Java 11)
  3. Window编译Opencv CUDA
  4. git submodule获取子模块
  5. 卧槽,B站联名键盘!
  6. mask属性是css3的吗_CSS3 mask 遮罩的具体使用方法
  7. matlab 仿照案例-目标检测
  8. qchart 设置线颜色_实战PyQt5: 137-QChart图表之散点图
  9. 外键列到底要建在哪里?
  10. Java SE之正则表达式二:匹配
  11. python:sklearn 标签编码(LabelEncoder)
  12. 异贝,通过移动互联网技术,为中小微实体企业联盟、线上链接、线上线下自定义营销方案推送。案例28
  13. 微信小程序双击底部导航栏刷新页面
  14. 银联统一规范的收单业务消息域
  15. 浙江大学14届计算机学院孙晓宇,郑州外国语学校2011年保送生录取名单
  16. antd-design库iconfont字体本地化
  17. Cadence Allegro修改静态铜皮为动态铜皮图文教程及视频演示
  18. 从IP138上获取数据,查询多个IP的归宿地
  19. 树莓派4B安装Ubuntu Mate20.04
  20. Linux磁盘管理工具RAID、Parted

热门文章

  1. base.apk软件下载免费_PS软件各版本免费下载地址
  2. pip安装pytorch慢
  3. H1N1猪流感症状及预防
  4. 奇兔recovery卡刷教程_vivo X6(双4G)刷Recovery教程
  5. mobl:针对移动Web开发的DSL【很详细】
  6. 又一个加密PHP脚本的解码方法
  7. 计算机应用系统的基本特征是什么,B是计算机应用系统的基本特征.doc
  8. AT2657 Mole and Abandoned Mine
  9. luckysheet 个人使用总结
  10. MongoDB-Java的两个基本操作Upsert和insertMany