Questions tagged [domain-calculus]

Tag for Domain Relational Calculus since [domain-relational-calculus] is too long for a tag.

13 questions
14
votes
3 answers

Difference between Relational Algebra and Relational calculus

What is the exact difference between relational algebra and relational calculus? At most references, it will be Relational algebra is procedural and calculus is non-procedural. What do these terms mean? We can solve all problems using relational…
2
votes
2 answers

Procedural and non-procedural query language difference

Going through the relational algebra, I encountered the term "procedural query language". So what is the difference between a procedural query language and a non-procedural query language?
2
votes
1 answer

Expressing relational calculus & algebra queries in plain English re passengers, flights & trips in economy

I have this statement: And this one: How do I go about converting these to plain English? Here is the extent of my understanding: For the first one, I think it's selecting p_id where there exists f_no1, f_date and f_no2 from the Flight and…
Ogen
  • 6,499
  • 7
  • 58
  • 124
1
vote
1 answer

Views in relational calculus

I was wondering if we can somehow define a view in relational calculus to split complex queries onto several smaller ones? Or do we have to write big queries as a composite?
0
votes
1 answer

about query in domain relational calculus

There are 2 relations: Prediction(cname, etype) Measures(etype, provider) cname - city name of predicted future disaster. etype - event type. earthquake, tsunami... provider - police, ambulance... I need to write a query using domain relational…
Arthur
  • 81
  • 1
  • 1
  • 7
0
votes
1 answer

Relational Algebra and Domain Relational Calculus for SQL Query

Tables: Contest(starter, ender, pointsStarter, pointsEnder, debatedate) Debater(name, club, age) Query: Give all contest details of contests where the starting debater is a member of the "Plato" club and prevented his opponent from scoring any…
0
votes
1 answer

About query written in Domain Relational Calculus

I am trying to learn Domain relational calculus. Considering the below relations and queries, why can't we write for{|< b, l, c, a> ∈ borrow ∧ a>1200} the second question? I have a feeling that it has something to do with whether the query is…
user3735871
  • 527
  • 2
  • 14
  • 31
0
votes
1 answer

How would I find the highest/largest of something with relation algebra, domain relational calculus and tuple relational calculus

This is part of a homework assignment. I've got several questions asking find the eid of the employee with the highest salary, or 2nd highest salary. Find the pilot that is certified for the most aircrafts. I don't have any idea on how to do it.…
Justen
  • 4,859
  • 9
  • 44
  • 68
0
votes
0 answers

Domain Relational Calculus unsafe query

I'm not sure how the following is an unsafe query. "Unsafe query" means that the answer set is infinite. I seek an explanation of why it is an unsafe query because I don't understand the query. There are 2 tables: invoice number(PK) customer …
user1097856
  • 159
  • 3
  • 15
-1
votes
1 answer

Convert Domain Calculus into (Postgre-)SQL

Let there be a table Person with attributes (columns) Name and Age. Given the following expression in Domain Calculus: {[name] | ∃ age (Person(name,age) ∧ age≥18)} I want to create the corresponding SQL query. Is it possible (not asking if it is…
CodingTil
  • 447
  • 2
  • 16
-1
votes
3 answers

What is TRC and DRC in DBMS?

What is tuple relational calculus (TRC) and domain relational calculus (DRC)? How do they differ with relational algebra? I am new in DBMS field. But I have learned basics of relational algebra.
-1
votes
2 answers

domain relational calculus "for all" expression

I have database of University like below: Student (SID, name, family, mean, age, city, street, CID) Instructor (IID, name, family, salary, city, street, CID) College (CID, name, city) How can i answer the following query in Domain Relational…
-2
votes
1 answer

How to decide whether this query in domain relational calculus is domain-independent?

I am trying to understand whether the following query is domain-independent: {t : ∀x ∀y ( (x≠y ∧ R(t,x) ∧ T(t,y)) → S(x,y) ) I think that this query is domain-independent because the left side of → forces it to be in every domain. Is that so?