Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [databases]

The tag has no usage guidance.

0
votes
0answers
10 views

Why “ every non-prime attribute of R is non-transitively dependent on every key of R” in the original def of 3NF?

I have read the definition in of Third_normal_form here , which shows The third normal form (3NF) is a normal form used in database normalization. 3NF was originally defined by E.F. Codd in 1971.[2]...
-4
votes
0answers
139 views

Need for Speed: Parallelism [closed]

Parallelism sometimes called parallel execution divides a task among multiple processes so that instead of doing all the work by one process in a query, many processes perform part of the work at the ...
1
vote
0answers
18 views

Why don't RDBMS use a quorum based solution to do failover

For RDBMS viz. MySql, PostgreSql a common solution for scalability and high availability is to run a primary instance as master that is a read-write instance and one or more read replicas. If the ...
0
votes
1answer
29 views

Doubt regarding foreign key and referential integrity

I am studying database from Database System Concepts. The author was explaining foreign keys and referential integrity with the help of following schemas: $$ instructor(\underline{ID},\space name,\...
0
votes
0answers
8 views

view serialisable and conflict serialisable

I recently was solving some problems on these topic and realised that in cases where conflict serialisable schedule existed; the number of view serialisable schedule was actually equal to the number ...
0
votes
0answers
16 views

When BCNF decomposition preserves Functional Dependencies?

It is known that BCNF decomposition does not preserve functional dependencies (FDs). For example, for FDs on R(A,B,C), ...
0
votes
3answers
55 views

Functional Dependencies

Let relational schema R(A,B,C,D,E,F,G,H,I). The functional dependencies are: A -> BC, AD -> BE, C ->F , A->F , D-> E Find the number of non-trivial functional dependencies ? I know that R has only ...
0
votes
0answers
69 views

How are these two definitions of the Third Normal Form (3NF) equivalent?

According to the textbook by Silberschatz, A relation schema R is in third normal form with respect to a set $F$ of functional dependencies if, for all functional dependencies in $F^+$ of the form $\...
0
votes
0answers
57 views

Any Recoverable schedule which is not a Cascadeless schedule?

When I read about Cascadeless schedule, it says "Every Cascadeless schedule is also recoverable schedule." and the examples are also almost same. I want to know an example of Recoverable schedule ...
0
votes
0answers
10 views

Is a schedule with autocommit and no aborts automatically recoverable?

As in the title, since we won't have problems with cascading aborts and each transaction is committed automatically, doesn't this mean that the schedule will always be recoverable?
0
votes
1answer
28 views

Given a relation and asked to enumerate all FD's and mark the trivial FD's

Given a relation R(A,B,C) and a FD set (A->B, B->C), find the FD Closure. Enumerate all the FD's and organize them accordingly to the LHS of the FD's. Mark all the trivial FD's. I am a little ...
0
votes
1answer
21 views

Maximum join of relations

I have a question as follows Consider the relations $r1(P, Q, R)$ and $r2(R, S, T)$ with primary keys $P$ and $R$ respectively. The relation $r1$ contains $2000$ tuples and $r2$ contains $2500$ ...
0
votes
1answer
28 views

How to decompose into BCNF while preserving all functional dependencies

I have a relation R = {A,B,C} and F={AB -> C , C -> B}. In order to check if R is in BCNF. I checked if AB and C are both superkeys and since C is not a superkey I conclude R is not in BCNF. After ...
1
vote
1answer
30 views

Is my decomposition of R into 3NF is lossless and preserving all dependencies?

I have a schema R = {A,B,C,D,E} and the set F of FDs: F = {A --> BCDE, CD --> E, EC --> B}. Candidate key = A Non - Prime Attributes = BCDE Prime Attributes = A According to me, there is no partial ...
0
votes
1answer
31 views

Did Date and Darwen's “Third Manifesto” have a lasting impact?

In 1995, two DB theory researchers, C.J. Date and H. Darwen, published a text with the rather impressive-sounding name "The Third Manifesto" with their ideas regarding future DBMSes, which would ...
-1
votes
2answers
81 views

Is it possible to do a NULL comparison in Relational Algebra?

Please consider the following question given in a booklet: I have read about databases from Database System Concepts - by Henry F. Korth, but never saw an instance where we could do a NULL comparison ...
1
vote
1answer
48 views

Raft algorithm: What's the data format of `term`?

Time is divided into terms, and each term begins with an election. After a successful election, a single leader manages the cluster until the end of the term. Some elections fail, in which case the ...
1
vote
0answers
37 views

How to determine conflict serializability without read and writes

I'm learning about conflict serializability in an introduction to databases class. I know how to check if a schema of transactions is conflict serializable when there's reads and writes. Draw the ...
1
vote
0answers
23 views

normalization: how does nf work?

I once did normalization for my Computer Science project, and I had to turn 0NF to 1NF, 2NF and 3NF. What must we actually do to convert 0NF to 1NF, 2NF and 3NF? Must we rearrange the information and ...
1
vote
0answers
20 views

Merge unstructured with structured data

We have a database with well-formated and structured data. From time to time we get Excel - files from our clients. This Excel Files have to be imported to the database. It it very important that we ...
-2
votes
1answer
35 views

How to find information quickly in a table

I have a table and asked me to add my information to it. And then asked me to find my information in the easiest way (after adding your details to the table, assume that the table is arranged ...
0
votes
0answers
84 views
0
votes
1answer
78 views

Where do you exactly use data structures?

I know what data structures is, How it works & importance of it. I just have some doubts on where do we actually use it. When database can do filtering, fetching, sorting efficiently, Why we ...
-3
votes
2answers
196 views

How many candidate keys are there in the table shown below?

One candidate key is (report_no, author_id). What are the other candidate keys?
0
votes
1answer
44 views

Checking claim in paper “A Read-Only Transaction Anomaly Under Snapshot Isolation” by Alan Fekete et al

In the 2004 paper "A Read-Only Transaction Anomaly Under Snapshot Isolation" by Alan Fekete et al. (which can be found here and here) the authors state: We also note that any execution of T1 and T2 ...
0
votes
1answer
44 views

What are the essential differences and similarities among “data”, “Information” and “knowledge” in the context of Computer Science?

The terms "data", "information" and "knowledge" are quite interchangeably used in Computer Science. Strictly speaking, they do carry a very different meaning. I want to know their precise meanings and ...
0
votes
1answer
19 views

Is relation following given characteristic already in 2NF, 3NF and BCNF?

The definitions of 2NF, 3NF and BCNF goes like this: 2 Normal Form (NF) definition A relation is in second normal form if and only if it is in first normal form and all the non-key attributes ...
0
votes
1answer
100 views

Use of existential quantifier in tuple relational calculus

It is somewhat confusing to me when to use quantifiers in tuple relational calculus (TRC). I stumbled upon following problem and I am still scratching my head thinking why not TRC query can be ...
-2
votes
1answer
68 views

Query Super Type and Subtype in Mysql

Assuming I have a schema depicted in the image , showing relationships(specialization) between Staffs, Academic Staffs and Non Academic Staffs. Is it possible to have a query that retrieves the ...
0
votes
0answers
74 views

Data structure for a single elimination tournament and its implementation

I want to implement a tournament managing software , something like challonge(https://challonge.com/) and am currently stuck at the data structure to be used. I read up on tournament trees and a ...
0
votes
0answers
57 views

Databases - How to generalize an sql query from a specific input? find project number, number of employees

Schema: http://comet.lehman.cuny.edu/jung/cmp420758/DBMidexamFa14-SelectedSolution.pdf Write SQL code to find the following details: For each project: find the project number and the number of ...
2
votes
1answer
61 views

Fastest way to search a word in a word list?

I have a word list like "English Open Word List" used to create word games. The list is in txt file with space between words, like; aa aah aahed .........and so on. I want to search it while typing ...
0
votes
0answers
102 views

Calculate order of Leaf and Non-leaf nodes of B tree

Consider a disk with a block size $B=512$ bytes. A block pointer is $P=6$ bytes and a record pointer is $P_R=7$ bytes. A file has $r=30000$ records of fixed length, with a record size of $r=116$ ...
4
votes
0answers
33 views

Any elegant approach to search where users have permissions on subset of records?

I work in Search and have seen following problem appear in different forms. There are many users in an enterprise; they have ability to create records. Each user has variable level of access to some ...
-1
votes
1answer
110 views

What is the equivalent form of full outer join in relational algebra?

Considering only basic relational algebra operations, how can we implement the full outer-join ?
2
votes
1answer
77 views

How to do compare-and-increment different locations with in memory MVCC?

I'm reading the paper An Empirical Evaluation of In-Memory Multi-Version Concurrency Control which is about implementations of MVCC for in-memory databases. Section 3.3 on Two-phase Locking (MV2PL) ...
1
vote
0answers
95 views

Question regarding ER Diagram design

I'm working through a Database Design textbook, and one of the problems involving ER Diagram design is giving me some trouble. The diagram is for a UNIVERSITY database with the following rules: 1) ...
0
votes
1answer
237 views

Transitive dependency in 3NF

Came across this question : State whether True or False A prime attribute can be transitively dependent on a key in 3NF Answer: True How could this be true? Because as far as I know, A relation ...
0
votes
0answers
15 views

concurrency control in real time database

Can Lamport's Bakery algorithm be used for controlling concurrency in soft real time database system (case study of stock trading)?
1
vote
1answer
931 views

Why must a Primary Index be sparse?

Reading Fundamentals of Database Systems 7th Edition, on Page 603, it says, Indexes can also be characterized as dense or sparse. A dense index has an index entry for every search key value (and ...
0
votes
2answers
192 views

Does 2NF require 1NF?

From Database System Concepts, by Silberschatz, Korth and Sudarshan : A domain is atomic if elements of the domain are considered to be indivisible units. We say that a relation schema ...
1
vote
1answer
143 views

Are all relational schemas with partial dependencies not in 3NF?

From Database Management Systems, by Raghu Ramakrishnan, ‎Johannes Gehrk Let R be a relation schema, F be the set of ...
0
votes
2answers
4k views

Order of a leaf node in B+ Tree

Going with the definition, that order of a B+ tree is the maximum number of children a node can have. What is exactly meant by the order of a leaf node? As per my understanding order of a leaf node ...
0
votes
0answers
104 views

Domain relational calculus to relational algebra

I have an expression in DRC $\{\langle a,b,c \rangle \mid \langle a,b \rangle \in r \land \langle a,b \rangle \in s\}$, where $r = (A,B)$ and $s = (A,C)$. I want to convert it onto relational algebra ...
0
votes
0answers
58 views

Differences among meta-data, catalog, data dictionary, and schema

What is the exact meaning of these terms? Very confusing. Most of the articles uses these terms interchangeably.
2
votes
2answers
28 views

Inferring used fields in return type

A common issue in app development is avoiding over-fetching of data, such as in this naive (pseudocode) example: ...
2
votes
1answer
56 views

If we allow a database, what complexity class it is?

Let we have some problem $A$. Input length is $n$. Now we write a database that will store info about some positive instances of problem $A$. For every $n$ size of $n^{th}$ sector of DB is $O(f(n))$. $...
0
votes
1answer
212 views

SQl query output

Consider the table employee(empId, name, department, salary) and the two queries Q1 ,Q2 below. Assuming that department 5 has more than one employee, and we want to find the employees who get higher ...
-2
votes
1answer
33 views
1
vote
0answers
32 views

which paper to take that would best fit to becoming a data scientist? [closed]

My name is Webber from Auckland, New Zealand. I am currently in my second year studying the bachelor of computer and information science. I have chosen to do a double major in computational ...