MESSAGE
DATE | 2014-12-11 |
FROM | Ruben
|
SUBJECT | Re: [LIU Comp Sci] Database Class concepts which are still unclear
|
From owner-learn-outgoing-at-mrbrklyn.com Thu Dec 11 12:57:41 2014 Return-Path: X-Original-To: archive-at-mrbrklyn.com Delivered-To: archive-at-mrbrklyn.com Received: by mrbrklyn.com (Postfix) id 31365161168; Thu, 11 Dec 2014 12:57:41 -0500 (EST) Delivered-To: learn-outgoing-at-mrbrklyn.com Received: by mrbrklyn.com (Postfix, from userid 28) id 14F4616116B; Thu, 11 Dec 2014 12:57:40 -0500 (EST) Delivered-To: learn-at-mrbrklyn.com Received: from mail-qc0-f181.google.com (mail-qc0-f181.google.com [209.85.216.181]) by mrbrklyn.com (Postfix) with ESMTP id 2F029161168 for ; Thu, 11 Dec 2014 12:57:40 -0500 (EST) Received: by mail-qc0-f181.google.com with SMTP id m20so4322388qcx.12 for ; Thu, 11 Dec 2014 09:57:39 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:message-id:date:from:user-agent:mime-version:to :subject:references:in-reply-to:content-type :content-transfer-encoding; bh=tGRd8COJ85K8tVZP7f+1xtlOVEQfzbhSFTUZcuWxYfs=; b=Y5YyQVkdvPu2IXAYySmMykBmQcw3bjMjjy7D3CkdvUvcsAgjTePW/QssyrtT61Ahlz QOYHrhC2clF+V0/epwhMz33GMfqmRoJH88mujG6b/yEvKzKn8XExuTp/X2JZBr7eihHD 8iZ77m31BTrCBFnLhmycF8J5i/0di8ENPhjBXXpY3/qfXV596F0DQJ7kMruteMJSL+M4 NiVoItptCJ/nL5Glo9ntMhjaW9PqiEYz4O7ij68BwWpLWPxZp822HL9BzdnP8TNIKjdD JzcueXS0xyElcicKcxvbEL27mK9yVLO+Qr5ETRB4JMElpRZkdd1LZHTYUlXlc+PDlfKm BsgQ== X-Gm-Message-State: ALoCoQlGZ/cVC+TA5WhFAQHbM5GS0MOTJb+9kcHo0Ivlj90vBHl5Hmr9F0CSinRKzATKvMuxkTdo X-Received: by 10.229.63.71 with SMTP id a7mr22443521qci.24.1418320659573; Thu, 11 Dec 2014 09:57:39 -0800 (PST) Received: from [10.0.0.42] ([96.57.23.82]) by mx.google.com with ESMTPSA id r12sm29788qax.38.2014.12.11.09.57.38 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 11 Dec 2014 09:57:39 -0800 (PST) Message-ID: <5489DB18.9000909-at-my.liu.edu> Date: Thu, 11 Dec 2014 12:57:44 -0500 From: Ruben User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0 MIME-Version: 1.0 To: learn-at-mrbrklyn.com, learn-at-nylxs.com, Ping-Tsai Chung Subject: Re: [LIU Comp Sci] Database Class concepts which are still unclear References: <5489C062.7010909-at-panix.com> In-Reply-To: <5489C062.7010909-at-panix.com> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Sender: owner-learn-at-mrbrklyn.com Precedence: bulk Reply-To: learn-at-mrbrklyn.com
Does anyone understand this. The way this is written it is not comprehendable. The text doesn't flow logically and example, which in theory is supposed to explain what the text does not, not not explain it which leave this and "magic logic" - And Blood of a Nwet and Poof, you get the desired chicken!
<<6.3.4 The DIVISION Operation The DIVISION operation, denoted by ÷, is useful for a special kind of query that sometimes occurs in database applications.>>
Really? What kind?
<< An example is Retrieve the names of employees who work on all the projects that ‘John Smith’ works on. >>
What class of query is this called and how is it generlized mathmatically.
<>
OK - we will learn by exmple since we have no definitions
<in the intermediate relation SMITH_PNOS:>>
OK
<SMITH_PNOS ? ?Pno(WORKS_ONEssn=SsnSMITH)>>
OK - that makes sense
<< Next, create a relation that includes a tuple whenever the employee whose Ssn is Essn works on the project whose number is Pno in the intermediate relation SSN_PNOS:>>
That is a lot of words that make NO SENSE. This sentence doesn't parse English Gammar in a way that is meaningful, which is interesting since this is a chapter on Relational Algrabra for which Grammar is a specific subset and application of.
In other words, I don't think the auther knows what he wrote here and his editor didn't know enough to fix it or clarify it. But we have an example:
<>
Fine this MEANS project all the tuples in WORKS_ON by restricting them to the attributes of Essn and Pno and assign it to a relationship we call SSN_PNOS
<gives the desired employees’ Social Security numbers:>>
PRESTO!!! Use this magic symbol and get your desired result!
<>
I have no idea what this does and it hasn't been explained. It is a waste of my time.
<>
And this says take a natural join of SSNS and EMPLOYEE and project just the names.
Now dissect the example more closely. Maybe "Presto" will show itself and a logical contruction.
SSN_PNOS
Essn Pno
123456789 1
123456789 2
666884444 3
453453453 1
453453453 2
333445555 2
333445555 3
333445555 10
333445555 20
999887777 30
999887777 10
987987987 10
987987987 30
987654321 30
987654321 20
888665555 20
SMITH_PNOS Pno 1 2 SSNS Ssn 123456789 453453453
Magic Results, no explanation. This is the kind of soft material that litters this class everywhere. I don't understand it and until you can explain it, I'm not convinced you understand it either.
On 12/11/2014 11:03 AM, Ruben Safir wrote: > 6.2.2 The CARTESIAN PRODUCT (CROSS PRODUCT) > Operation > Next, we discuss the CARTESIAN PRODUCT operation—also known as CROSS > PRODUCT or CROSS JOIN—which is denoted by ×. This is also a binary set > opera- > tion, but the relations on which it is applied do not have to be union > compatible. In > its binary form, this set operation produces a new element by combining > every > member (tuple) from one relation (set) with every member (tuple) from > the other > relation (set). In general, the result of R(A1, A2, ..., An) × S(B1, B2, > ..., Bm) is a rela- > tion Q with degree n + m attributes Q(A1, A2, ..., An, B1, B2, ..., Bm), > in that order. > The resulting relation Q has one tuple for each combination of > tuples—one from R > and one from S. Hence, if R has nR tuples (denoted as |R| = nR), and S > has nS tuples, > then R × S will have nR * nS tuples. > The n-ary CARTESIAN PRODUCT operation is an extension of the above concept, > which produces new tuples by concatenating all possible combinations of > tuples > from n underlying relations. > > > What is an n-ary operation? It is mentioned several times, but I don't > see an answer > > Ruben >
|
|