Updated slides
This commit is contained in:
parent
cfa49abf4f
commit
2d0fcc7ded
|
@ -87,7 +87,7 @@ In this course, you will learn...
|
|||
<li><strong>TAs: </strong><ul>
|
||||
<li>Darshana Balakrishnan: Office Hours TBD</li>
|
||||
</ul></li>
|
||||
<li><strong>Course Discussions: </strong> <a href="https://canvas.instructure.com/courses/2540988">Canvas</a></li>
|
||||
<li><strong>Course Discussions: </strong> <a href="https://piazza.com/buffalo/spring2021/cse462562">Piazza</a></li>
|
||||
<li><strong>No Required Textbook</strong></li>
|
||||
<li><strong>Optional References</strong>: <ul>
|
||||
<li>"Database Systems: The Complete Book" 2e. by Garcia-Molina, Ullman, and Widom</li>
|
||||
|
|
|
@ -4,8 +4,23 @@ title: Intro
|
|||
date: Feb 2, 2021
|
||||
textbook: "Ch. 1, 2.1-2.2"
|
||||
---
|
||||
<%
|
||||
sli_do_link = "
|
||||
<section>
|
||||
<img src='graphics/slido.png' width='300px'/><br/>
|
||||
<a href='https://app.sli.do/event/iobhymgr'>https://app.sli.do/event/iobhymgr</a>
|
||||
</section>
|
||||
"
|
||||
sli_do_link_small = "
|
||||
<img src='graphics/slido.png' width='150px'/>
|
||||
"
|
||||
%>
|
||||
<section>
|
||||
|
||||
<section>
|
||||
<img src="graphics/slido.png" width="300px"/><br/>
|
||||
<a href="https://app.sli.do/event/iobhymgr">https://app.sli.do/event/iobhymgr</a>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Why Are Databases Awesome?</h2>
|
||||
|
@ -119,7 +134,7 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<td>Sunnyvale, CA, US
|
||||
</td></tr>
|
||||
</table>
|
||||
<p class="fragment" data-fragment-index="1">8 of 9 Forbes Top Software Companies<br/>Have a Focus on Data Management Systems</p>
|
||||
<p class="fragment" data-fragment-index="1">8 of 10 Forbes Top Software Companies<br/>Have a Focus on Data Management Systems</p>
|
||||
<imagecredits><a href="https://en.wikipedia.org/wiki/List_of_the_largest_software_companies">(Source wikipedia.org)</a></imagecredits>
|
||||
</section>
|
||||
|
||||
|
@ -128,6 +143,17 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<img src="../../../../slides/cse4562sp2018/graphics/2018-01-29-db_interesting.svg" />
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<iframe src="https://app.sli.do/event/iobhymgr/embed/polls/9a03617f-d1d7-451e-b4a0-6e69d6db41e7" width="300" height="400"></iframe>
|
||||
</section>
|
||||
|
||||
</section>
|
||||
|
||||
|
||||
<section>
|
||||
<section>
|
||||
<iframe src="https://app.sli.do/event/iobhymgr/embed/polls/9d89e50e-846c-4315-a145-dfb97ab54fb5" width="300" height="400"></iframe>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
<!-- ================================================================ -->
|
||||
|
@ -138,6 +164,7 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<h1>What is "Databases"?
|
||||
</section>
|
||||
|
||||
|
||||
<section>
|
||||
<h3 style="padding-bottom: 60px;">How do we ask and answer questions about data?</h3>
|
||||
<h3>How do we manipulate and persist data?</h3>
|
||||
|
@ -232,7 +259,10 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<p style="font-size: small">(same link)</p>
|
||||
|
||||
<h3 style="margin-top: 50px;">CMS (Forum, Assignments)</h3>
|
||||
<p><a href="https://canvas.instructure.com/courses/2540988">https://canvas.instructure.com/courses/2540988https://canvas.instructure.com/courses/2540988</a></p>
|
||||
<p><a href="https://piazza.com/buffalo/spring2021/cse462562">https://piazza.com/buffalo/spring2021/cse462562</a></p>
|
||||
|
||||
<h3 style="margin-top: 50px;">Polls</h3>
|
||||
<p><a href="https://app.sli.do/event/iobhymgr">https://app.sli.do/event/iobhymgr</a></p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
|
@ -256,6 +286,10 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
</table>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<iframe src="https://app.sli.do/event/iobhymgr/embed/polls/12d6bbf3-c0f0-4af5-ae45-feb5e884c301" width="300" height="400"></iframe>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h3>Course Structure</h3>
|
||||
|
||||
|
@ -268,7 +302,7 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
</ul></dd>
|
||||
<dt>Practicum (50% of Grade)</dt>
|
||||
<dd><ul class="tight">
|
||||
<li>Rebuild the guts of Apache SparkSQL</li>
|
||||
<li>Rebuild the guts of Spark's Catalyst Engine</li>
|
||||
<li>Solo Project</li>
|
||||
<li>4 Checkpoints (+ 5 free points for Checkpoint 0)</li>
|
||||
</ul></dd>
|
||||
|
@ -294,19 +328,29 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<section>
|
||||
|
||||
<section>
|
||||
<img src="graphics/Clipart/ApacheSpark.png" height="150px" />
|
||||
<img src="graphics/Clipart/ApacheSpark.png" height="300px" />
|
||||
</section>
|
||||
|
||||
<p class="fragment">I've torn the guts out of Apache Spark. <br/>
|
||||
<b>Your mission</b>: Replace them (sort of).</p>
|
||||
<ul>
|
||||
<section>
|
||||
<p>I've torn the guts out of Catalyst. What remains:
|
||||
<ul class="fragment" style="font-size: 80%;">
|
||||
<li>SQL Parser</li>
|
||||
<li>Logical Plans: Relational Algebra Trees</li>
|
||||
<li>Expression: Primitive-valued expression trees + evaluation logic</li>
|
||||
</ul>
|
||||
</p>
|
||||
|
||||
<p class="fragment"><b>Your mission</b>: Replace the missing bits (sort of).</p>
|
||||
<ul style="font-size: 80%;">
|
||||
<li class="fragment">Analysis: Tidying up SQL's corner cases</li>
|
||||
<li class="fragment">Execution: Answering queries fast <span class="fragment">(single-node)</span></li>
|
||||
<li class="fragment">Optimization: Eliminating redundancy</li>
|
||||
<li class="fragment">Optimization: Eliminating redundancy <br/>and picking the best algorithms.</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h3>We give you...</h3>
|
||||
<p style="font-size: smaller;">Gutted Catalyst</p>
|
||||
<p style="font-size: smaller;">Data (CSV Files)</p>
|
||||
<p style="font-size: smaller;">Schema Information (CREATE TABLE)</p>
|
||||
<p style="font-size: smaller;">Questions (SQL Queries)</p>
|
||||
|
@ -346,7 +390,7 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<h3>Checkpoint 1: "Get it Working"</h3>
|
||||
<p style="font-size: smaller;">10/50 pts</p>
|
||||
<ul>
|
||||
<li>Interpret Relational Algebra (Spark <span style="font-family: fixed;">Operator</span>s)</li>
|
||||
<li>Interpret Relational Algebra (Spark's <tt>LogicalPlan</tt>)</li>
|
||||
<li>Load CSV Files</li>
|
||||
<li>Run Basic Select, Project, Join Queries</li>
|
||||
<li>Nested Queries</li>
|
||||
|
@ -362,14 +406,14 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
<h3>Checkpoint 3: "Precomputation"</h3>
|
||||
<h3>Checkpoint 3: "Aggregates"</h3>
|
||||
<p style="font-size: smaller;">8/50 pts</p>
|
||||
<ul>
|
||||
<li>Aggregation</li>
|
||||
</ul>
|
||||
</section>
|
||||
<section>
|
||||
<h3>Checkpoint 4: "The Real World"</h3>
|
||||
<h3>Checkpoint 4: "Precomputation"</h3>
|
||||
<p style="font-size: smaller;">15/50 pts</p>
|
||||
<ul>
|
||||
<li>You get a few minutes to pre-compute</li>
|
||||
|
@ -378,6 +422,10 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<li>Build indexes</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<iframe src="https://app.sli.do/event/iobhymgr/embed/polls/96e75b44-d00a-494a-961a-942bcbf7bfac" width="300" height="400"></iframe>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
||||
|
@ -389,7 +437,7 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<ul>
|
||||
<li>Start your project at the last minute</li>
|
||||
<li>Don’t go to office hours</li>
|
||||
<li>Don’t ask questions (on Canvas or in class)</li>
|
||||
<li>Don’t ask questions (on Piazza or in class)</li>
|
||||
<li>Wait until the deadline to submit for the first time</li>
|
||||
<li class="fragment">Cheat</li>
|
||||
</ul>
|
||||
|
@ -474,6 +522,10 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
</dl>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<iframe src="https://app.sli.do/event/iobhymgr/embed/polls/dd2349dc-13a5-4b92-b223-29b459d80d70" width="300" height="400"></iframe>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<svg data-src="graphics/2021-02-02-fs_vs_db.svg" />
|
||||
</section>
|
||||
|
@ -505,17 +557,21 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<section>
|
||||
<p>
|
||||
Your data is currently an <i>Unordered Set</i> <br/>
|
||||
of <i>Tuples</i> with 100 fields each.
|
||||
of <i>Tuples</i> with 100 attributes each.
|
||||
</p>
|
||||
|
||||
<p class="fragment" style="margin-top: 50px;">
|
||||
Tomorrow, you’ll be repeatedly asked for <i>1 specific attribute</i><br/>
|
||||
of <i>5 specific rows</i> identified by the <i>first attribute</i>
|
||||
from <i>5 specific tuples</i> identified by the <i>first attribute</i>
|
||||
</p>
|
||||
|
||||
<h3 class="fragment">Can you do better?</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<%= sli_do_link %>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<p><b>Better Idea</b>: Rewrite data into a 99-Tuple of Maps keyed on the 1st attribute</p>
|
||||
<p class="fragment" style="margin-top: 50px;">This representation is <u>equivalent</u> and <u>better</u> for your needs.</p>
|
||||
|
@ -523,3 +579,248 @@ textbook: "Ch. 1, 2.1-2.2"
|
|||
<p class="fragment" style="margin-top: 50px; font-weight: bold;">Declarative specifications make it easier to find equivalences.</p>
|
||||
</section>
|
||||
</section>
|
||||
|
||||
|
||||
<section>
|
||||
<section>
|
||||
<h2>Declarative Languages</h2>
|
||||
|
||||
<ul>
|
||||
<li class="fragment">Don't need to think about algorithms.</li>
|
||||
<li class="fragment">Independent of the data representation.</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>SQL</h2>
|
||||
<ul>
|
||||
<li>Developed by IBM (for System R) in the 1970s.</li>
|
||||
<li>Standard used by many vendors.<ul style="font-size: 70%" class="tight">
|
||||
<li>SQL-86 (original standard)</li>
|
||||
<li>SQL-89 (minor revisions; integrity constraints)</li>
|
||||
<li>SQL-92 (major revision; basis for modern SQL)</li>
|
||||
<li>SQL-99 (XML, window queries, generated default values)</li>
|
||||
<li>SQL 2003 (major revisions to XML support)</li>
|
||||
<li>SQL 2008 (minor extensions)</li>
|
||||
<li>SQL 2011 (minor extensions; temporal databases)</li>
|
||||
</li></ul>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h3>A Basic SQL Query</h3>
|
||||
<svg data-src="graphics/2021-02-02-parts_of_sql.svg" height="400px"/>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<pre><code class="sql">
|
||||
SELECT [DISTINCT] targetlist
|
||||
FROM relationlist
|
||||
WHERE condition
|
||||
</code></pre>
|
||||
<ol>
|
||||
<li class="fragment">Compute the $2^n$ combinations of tuples in all relations appearing in <span style="color: red;">relationlist</span></li>
|
||||
<li class="fragment">Discard tuples that fail the <span style="color: red;">condition</span></li>
|
||||
<li class="fragment">Delete attributes not in <span style="color: red;">targetlist</span></li>
|
||||
<li class="fragment">If <span style="font-family: Courier, fixedwidth;">DISTINCT</span> is specified, eliminate duplicate rows</li>
|
||||
</ol>
|
||||
<p style="font-size: 70%;" class="fragment">
|
||||
This is the least efficient strategy to compute a query!
|
||||
A good optimizer will find <b>more efficient strategies</b> to compute <b>the same answer.</b>
|
||||
</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h3>Example Data</h3>
|
||||
<img src="../../../../slides/cse4562sp2018/graphics/2018-01-31-Trees.png" height="500px">
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<pre><code class="SQL">SELECT * FROM Trees;</code></pre>
|
||||
|
||||
<p class="fragment" style="font-size: 70%">Wildcards (<code>*</code>, <code>tablename.*</code>) are special targets that select all attributes.</p>
|
||||
|
||||
<div style="width: 800px; overflow-x: scroll; font-size: small; margin-left: auto; margin-right: auto;" class="fragment">
|
||||
<table>
|
||||
<tr><th>CREATED_AT</th><th>TREE_ID</th><th>BLOCK_ID</th><th>THE_GEOM</th><th>TREE_DBH</th><th>STUMP_DIAM</th><th>CURB_LOC</th><th>STATUS</th><th>HEALTH</th><th>SPC_LATIN</th><th>SPC_COMMON</th><th>STEWARD</th><th>GUARDS</th><th>SIDEWALK</th><th>USER_TYPE</th><th>PROBLEMS</th><th>ROOT_STONE</th><th>ROOT_GRATE</th><th>ROOT_OTHER</th><th>TRNK_WIRE</th><th>TRNK_LIGHT</th><th>TRNK_OTHER</th><th>BRNCH_LIGH</th><th>BRNCH_SHOE</th><th>BRNCH_OTHE</th><th>ADDRESS</th><th>ZIPCODE</th><th>ZIP_CITY</th><th>CB_NUM</th><th>BOROCODE</th><th>BORONAME</th><th>CNCLDIST</th><th>ST_ASSEM</th><th>ST_SENATE</th><th>NTA</th><th>NTA_NAME</th><th>BORO_CT</th><th>STATE</th><th>LATITUDE</th><th>LONGITUDE</th><th>X_SP</th><th>Y_SP</th></tr>
|
||||
<tr><td>'08/27/2015'</td><td>180683</td><td>348711</td><td>'POINT (-73.84421521958048 40.723091773924274)'</td><td>3</td><td>0</td><td>'OnCurb'</td><td>'Alive'</td><td>'Fair'</td><td>'Acer rubrum'</td><td>'red maple'</td><td>'None'</td><td>'None'</td><td>'NoDamage'</td><td>'TreesCount Staff'</td><td>'None'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'108-005 70 AVENUE'</td><td>'11375'</td><td>'Forest Hills'</td><td>406</td><td>4</td><td>'Queens'</td><td>29</td><td>28</td><td>16</td><td>'QN17'</td><td>'Forest Hills'</td><td>4073900</td><td>'New York'</td><td>40.72309177</td><td>-73.84421522</td><td>1027431.14821</td><td>202756.768749</td></tr>
|
||||
<tr><td>'09/03/2015'</td><td>200540</td><td>315986</td><td>'POINT (-73.81867945834878 40.79411066708779)'</td><td>21</td><td>0</td><td>'OnCurb'</td><td>'Alive'</td><td>'Fair'</td><td>'Quercus palustris'</td><td>'pin oak'</td><td>'None'</td><td>'None'</td><td>'Damage'</td><td>'TreesCount Staff'</td><td>'Stones'</td><td>'Yes'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'147-074 7 AVENUE'</td><td>'11357'</td><td>'Whitestone'</td><td>407</td><td>4</td><td>'Queens'</td><td>19</td><td>27</td><td>11</td><td>'QN49'</td><td>'Whitestone'</td><td>4097300</td><td>'New York'</td><td>40.79411067</td><td>-73.81867946</td><td>1034455.70109</td><td>228644.837379</td></tr>
|
||||
<tr><td>'09/05/2015'</td><td>204026</td><td>218365</td><td>'POINT (-73.93660770459083 40.717580740099116)'</td><td>3</td><td>0</td><td>'OnCurb'</td><td>'Alive'</td><td>'Good'</td><td>'Gleditsia triacanthos var. inermis'</td><td>'honeylocust'</td><td>'1or2'</td><td>'None'</td><td>'Damage'</td><td>'Volunteer'</td><td>'None'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'390 MORGAN AVENUE'</td><td>'11211'</td><td>'Brooklyn'</td><td>301</td><td>3</td><td>'Brooklyn'</td><td>34</td><td>50</td><td>18</td><td>'BK90'</td><td>'East Williamsburg'</td><td>3044900</td><td>'New York'</td><td>40.71758074</td><td>-73.9366077</td><td>1001822.83131</td><td>200716.891267</td></tr>
|
||||
<tr><td>'09/05/2015'</td><td>204337</td><td>217969</td><td>'POINT (-73.93445615919741 40.713537494833226)'</td><td>10</td><td>0</td><td>'OnCurb'</td><td>'Alive'</td><td>'Good'</td><td>'Gleditsia triacanthos var. inermis'</td><td>'honeylocust'</td><td>'None'</td><td>'None'</td><td>'Damage'</td><td>'Volunteer'</td><td>'Stones'</td><td>'Yes'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'1027 GRAND STREET'</td><td>'11211'</td><td>'Brooklyn'</td><td>301</td><td>3</td><td>'Brooklyn'</td><td>34</td><td>53</td><td>18</td><td>'BK90'</td><td>'East Williamsburg'</td><td>3044900</td><td>'New York'</td><td>40.71353749</td><td>-73.93445616</td><td>1002420.35833</td><td>199244.253136</td></tr>
|
||||
<tr><td>'08/30/2015'</td><td>189565</td><td>223043</td><td>'POINT (-73.97597938483258 40.66677775537875)'</td><td>21</td><td>0</td><td>'OnCurb'</td><td>'Alive'</td><td>'Good'</td><td>'Tilia americana'</td><td>'American linden'</td><td>'None'</td><td>'None'</td><td>'Damage'</td><td>'Volunteer'</td><td>'Stones'</td><td>'Yes'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'No'</td><td>'603 6 STREET'</td><td>'11215'</td><td>'Brooklyn'</td><td>306</td><td>3</td><td>'Brooklyn'</td><td>39</td><td>44</td><td>21</td><td>'BK37'</td><td>'Park Slope-Gowanus'</td><td>3016500</td><td>'New York'</td><td>40.66677776</td><td>-73.97597938</td><td>990913.775046</td><td>182202.425999</td></tr>
|
||||
<tr class="fragment"><td colspan="42" style="text-align: left; font-weight: bold;">... and 683783 more</td></tr>
|
||||
</table>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<pre><code class="sql">
|
||||
SELECT tree_id, spc_common, boroname
|
||||
FROM Trees
|
||||
WHERE boroname = 'Brooklyn'
|
||||
</code></pre>
|
||||
|
||||
<p>In English, what does this query compute?</p>
|
||||
|
||||
<%= sli_do_link_small %>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<p style="font-size: smaller;">What is the ID, Commmon Name and Borough of Trees in Brooklyn?</p>
|
||||
|
||||
<table style="font-size: small;" class="fragment">
|
||||
<tr><th>TREE_ID</th><th>SPC_COMMON</th><th>BORONAME</th></tr>
|
||||
<tr><td>204026</td><td>'honeylocust'</td><td>'Brooklyn'</td></tr>
|
||||
<tr><td>204337</td><td>'honeylocust'</td><td>'Brooklyn'</td></tr>
|
||||
<tr><td>189565</td><td>'American linden'</td><td>'Brooklyn'</td></tr>
|
||||
<tr><td>192755</td><td>'London planetree'</td><td>'Brooklyn'</td></tr>
|
||||
<tr><td>189465</td><td>'London planetree'</td><td>'Brooklyn'</td></tr>
|
||||
<tr><td style="font-weight: bold;" colspan="3">... and 177287 more</td></tr>
|
||||
</table>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<pre><code class="sql">
|
||||
SELECT latitude, longitude
|
||||
FROM Trees, SpeciesInfo
|
||||
WHERE Trees.spc_common = SpeciesInfo.name
|
||||
AND SpeciesInfo.has_unpleasant_smell = 'Yes';
|
||||
</code></pre>
|
||||
|
||||
<p>In English, what does this query compute?</p>
|
||||
|
||||
<%= sli_do_link_small %>
|
||||
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<p style="font-size: smaller;">What are the coordinates of Trees with bad smells?</p>
|
||||
|
||||
<table style="font-size: small;" class="fragment">
|
||||
<tr><th>LATITUDE</th><th>LONGITUDE</th></tr>
|
||||
<tr><td>40.59378755</td><td>-73.9915968</td></tr>
|
||||
<tr><td>40.69149917</td><td>-73.97258754</td></tr>
|
||||
<tr><td>40.74829709</td><td>-73.98065645</td></tr>
|
||||
<tr><td>40.68767857</td><td>-73.96764605</td></tr>
|
||||
<tr><td>40.739991</td><td>-73.86526993</td></tr>
|
||||
<tr><td style="font-weight: bold;" colspan="5">... and more</td>
|
||||
</table>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<pre><code class="sql">
|
||||
SELECT Trees.latitude, Trees.longitude
|
||||
FROM Trees, SpeciesInfo
|
||||
WHERE Trees.spc_common = SpeciesInfo.name
|
||||
AND SpeciesInfo.has_unpleasant_smell = 'Yes';
|
||||
</code></pre>
|
||||
|
||||
<p style="font-size: smaller;">... is the same as ...</p>
|
||||
|
||||
<pre><code class="sql">
|
||||
SELECT T.latitude, T.longitude
|
||||
FROM Trees T, SpeciesInfo S
|
||||
WHERE T.spc_common = S.name
|
||||
AND S.has_unpleasant_smell = 'Yes';
|
||||
</code></pre>
|
||||
|
||||
<p style="font-size: smaller;">... is (usually) the same as ...</p>
|
||||
|
||||
<pre><code class="sql">
|
||||
SELECT latitude, longitude
|
||||
FROM Trees, SpeciesInfo
|
||||
WHERE spc_common = name
|
||||
AND has_unpleasant_smell = 'Yes';
|
||||
</code></pre>
|
||||
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Expressions</h2>
|
||||
|
||||
<pre><code class="sql">
|
||||
SELECT tree_id,
|
||||
stump_diam / 2 AS stump_radius,
|
||||
stump_area = 3.14 * stump_diam * stump_diam / 4
|
||||
FROM Trees;
|
||||
</code></pre>
|
||||
|
||||
<p style="font-size: 70%;">
|
||||
Arithmetic expressions can appear in targets or conditions.
|
||||
Use ‘=’ or ‘AS’ to assign names to these attributes.
|
||||
(The behavior of unnamed attributes is unspecified)
|
||||
</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Expressions</h2>
|
||||
|
||||
<pre><code class="sql">
|
||||
SELECT tree_id, spc_common FROM Trees WHERE spc_common LIKE '%maple'
|
||||
</code></pre>
|
||||
<table style="font-size: small;">
|
||||
<tr><th>TREE_ID</th><th>SPC_COMMON</th></tr>
|
||||
<tr><td>180683</td><td>'red maple'</td></tr>
|
||||
<tr><td>204325</td><td>'sycamore maple'</td></tr>
|
||||
<tr><td>205044</td><td>'Amur maple'</td></tr>
|
||||
<tr><td>184031</td><td>'red maple'</td></tr>
|
||||
<tr><td>208974</td><td>'red maple'</td></tr>
|
||||
</table>
|
||||
<p style="font-size: 70%;">SQL uses single quotes for ‘string literals’</p>
|
||||
<p style="font-size: 70%;"><code>LIKE</code> is used for String Matches</p>
|
||||
<p style="font-size: 70%;">‘<code>%</code>’ matches 0 or more characters</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Union</h2>
|
||||
<pre><code class="sql">
|
||||
SELECT tree_id FROM Trees WHERE spc_common = 'red maple'
|
||||
UNION [ALL]
|
||||
SELECT tree_id FROM Trees WHERE spc_common = 'sycamore maple'
|
||||
</code></pre>
|
||||
<p style="font-size: 70%">Computes the <b>set-union</b> of any two <b>union-compatible</b> sets of tuples</p>
|
||||
<p style="font-size: 70%">Adding <code>ALL</code> preserves duplicates across the inputs (<b>bag-union</b>).</p>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Aggregate Queries</h2>
|
||||
<pre><code class="sql">
|
||||
SELECT [DISTINCT] targetlist
|
||||
FROM relationlist
|
||||
WHERE condition
|
||||
GROUP BY groupinglist
|
||||
HAVING groupcondition
|
||||
</code></pre>
|
||||
<div style="font-size: 70%">
|
||||
<p>The <span color="red">targetlist</span> now contains <b>(a)</b> Grouped attributes, and <b>(b)</b> Aggregate expressions.</p>
|
||||
<p>Targets of type (a) must be a subset of the grouping-list</p>
|
||||
<p style="font-size: 70%">(intuitively each answer tuple corresponds to a single group, and each group must have a single value for each attribute)</p>
|
||||
<p style="margin-top: 20px"><span color="red">groupcondition</span> is applied <i>after</i> aggregation and may contain aggregate expressions.</p>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section>
|
||||
<h2>Aggregate Queries</h2>
|
||||
<pre><code class="sql">
|
||||
SELECT spc_common, count(*) FROM Trees GROUP BY spc_common
|
||||
</code></pre>
|
||||
<table style="font-size: small;">
|
||||
<tr><th>SPC_COMMON </th><th>COUNT</th></tr>
|
||||
<tr><td>''Schubert' chokecherry' </td><td>4888</td></tr>
|
||||
<tr><td>'American beech' </td><td>273</td></tr>
|
||||
<tr><td>'American elm' </td><td>7975</td></tr>
|
||||
<tr><td>'American hophornbeam' </td><td>1081</td></tr>
|
||||
<tr><td>'American hornbeam' </td><td>1517</td></tr>
|
||||
<tr><td colspan="2" style="font-weight: bold;">... and more</td>
|
||||
</table>
|
||||
|
||||
</section>
|
||||
|
||||
</section>
|
||||
|
||||
|
||||
<section>
|
||||
<h3>Next time...</h3>
|
||||
|
||||
<p>Scala for Java programmers.</p>
|
||||
</section>
|
||||
|
|
|
@ -0,0 +1,277 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="195.6194mm"
|
||||
height="147.07428mm"
|
||||
viewBox="0 0 195.6194 147.07428"
|
||||
version="1.1"
|
||||
id="svg8"
|
||||
inkscape:version="0.92.2 5c3e80d, 2017-08-06"
|
||||
sodipodi:docname="2018-01-31-parts_of_sql.svg">
|
||||
<defs
|
||||
id="defs2">
|
||||
<marker
|
||||
inkscape:stockid="Arrow1Lend"
|
||||
orient="auto"
|
||||
refY="0"
|
||||
refX="0"
|
||||
id="marker1545"
|
||||
style="overflow:visible"
|
||||
inkscape:isstock="true">
|
||||
<path
|
||||
id="path1543"
|
||||
d="M 0,0 5,-5 -12.5,0 5,5 Z"
|
||||
style="fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1"
|
||||
transform="matrix(-0.8,0,0,-0.8,-10,0)"
|
||||
inkscape:connector-curvature="0" />
|
||||
</marker>
|
||||
<marker
|
||||
inkscape:stockid="Arrow1Lend"
|
||||
orient="auto"
|
||||
refY="0"
|
||||
refX="0"
|
||||
id="marker1217"
|
||||
style="overflow:visible"
|
||||
inkscape:isstock="true">
|
||||
<path
|
||||
id="path1215"
|
||||
d="M 0,0 5,-5 -12.5,0 5,5 Z"
|
||||
style="fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1"
|
||||
transform="matrix(-0.8,0,0,-0.8,-10,0)"
|
||||
inkscape:connector-curvature="0" />
|
||||
</marker>
|
||||
<marker
|
||||
inkscape:isstock="true"
|
||||
style="overflow:visible"
|
||||
id="marker1175"
|
||||
refX="0"
|
||||
refY="0"
|
||||
orient="auto"
|
||||
inkscape:stockid="Arrow1Lend"
|
||||
inkscape:collect="always">
|
||||
<path
|
||||
transform="matrix(-0.8,0,0,-0.8,-10,0)"
|
||||
style="fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1"
|
||||
d="M 0,0 5,-5 -12.5,0 5,5 Z"
|
||||
id="path1173"
|
||||
inkscape:connector-curvature="0" />
|
||||
</marker>
|
||||
<marker
|
||||
inkscape:stockid="Arrow1Lend"
|
||||
orient="auto"
|
||||
refY="0"
|
||||
refX="0"
|
||||
id="Arrow1Lend"
|
||||
style="overflow:visible"
|
||||
inkscape:isstock="true"
|
||||
inkscape:collect="always">
|
||||
<path
|
||||
id="path848"
|
||||
d="M 0,0 5,-5 -12.5,0 5,5 Z"
|
||||
style="fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1"
|
||||
transform="matrix(-0.8,0,0,-0.8,-10,0)"
|
||||
inkscape:connector-curvature="0" />
|
||||
</marker>
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="0.7"
|
||||
inkscape:cx="154.41551"
|
||||
inkscape:cy="77.010708"
|
||||
inkscape:document-units="mm"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
fit-margin-top="0"
|
||||
fit-margin-left="0"
|
||||
fit-margin-right="0"
|
||||
fit-margin-bottom="0"
|
||||
inkscape:window-width="1920"
|
||||
inkscape:window-height="1031"
|
||||
inkscape:window-x="0"
|
||||
inkscape:window-y="1"
|
||||
inkscape:window-maximized="1" />
|
||||
<metadata
|
||||
id="metadata5">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title></dc:title>
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="Layer 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(-7.1997539,-2.9412171)">
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-weight:normal;font-size:10.58333302px;line-height:1.25;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.26458332"
|
||||
x="9.0714293"
|
||||
y="33.92857"
|
||||
id="text12"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan10"
|
||||
x="9.0714293"
|
||||
y="33.92857"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;stroke-width:0.26458332">SELECT [DISTINCT] <tspan
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#ff0000"
|
||||
id="tspan26">target-list</tspan></tspan><tspan
|
||||
sodipodi:role="line"
|
||||
x="9.0714293"
|
||||
y="47.219749"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;stroke-width:0.26458332"
|
||||
id="tspan14" /><tspan
|
||||
sodipodi:role="line"
|
||||
x="9.0714293"
|
||||
y="60.448914"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;stroke-width:0.26458332"
|
||||
id="tspan16" /><tspan
|
||||
sodipodi:role="line"
|
||||
x="9.0714293"
|
||||
y="73.678078"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;stroke-width:0.26458332"
|
||||
id="tspan18">FROM <tspan
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#ff0000"
|
||||
id="tspan28">relation-list</tspan></tspan><tspan
|
||||
sodipodi:role="line"
|
||||
x="9.0714293"
|
||||
y="86.969261"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;stroke-width:0.26458332"
|
||||
id="tspan20" /><tspan
|
||||
sodipodi:role="line"
|
||||
x="9.0714293"
|
||||
y="100.19843"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;stroke-width:0.26458332"
|
||||
id="tspan22" /><tspan
|
||||
sodipodi:role="line"
|
||||
x="9.0714293"
|
||||
y="113.42759"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;stroke-width:0.26458332"
|
||||
id="tspan24">WHERE <tspan
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:10.58333302px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#ff0000"
|
||||
id="tspan30">condition</tspan></tspan></text>
|
||||
<g
|
||||
id="g1131"
|
||||
class="fragment">
|
||||
<text
|
||||
id="text34"
|
||||
y="86.845245"
|
||||
x="11.339282"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;line-height:1.25;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.26458332"
|
||||
xml:space="preserve"><tspan
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#666666;stroke-width:0.26458332"
|
||||
y="86.845245"
|
||||
x="11.339282"
|
||||
id="tspan32"
|
||||
sodipodi:role="line">A list of relation names </tspan><tspan
|
||||
id="tspan36"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#666666;stroke-width:0.26458332"
|
||||
y="95.664688"
|
||||
x="11.339282"
|
||||
sodipodi:role="line">(possibly with a range-variable after each name)</tspan></text>
|
||||
<path
|
||||
inkscape:connector-curvature="0"
|
||||
id="path38"
|
||||
d="M 95.249999,84.577379 107.34524,76.261904"
|
||||
style="fill:none;stroke:#000000;stroke-width:0.26499999;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#Arrow1Lend)" />
|
||||
</g>
|
||||
<g
|
||||
id="g1253"
|
||||
transform="translate(23.434524,-37.041667)"
|
||||
class="fragment">
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;line-height:1.25;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.26458332"
|
||||
x="-7.5595274"
|
||||
y="89.869057"
|
||||
id="text1163"><tspan
|
||||
sodipodi:role="line"
|
||||
x="-7.5595274"
|
||||
y="89.869057"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#666666;stroke-width:0.26458332"
|
||||
id="tspan1161">A list of attributes of relations in <tspan
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;font-family:Courier;-inkscape-font-specification:'Courier, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#ff0000"
|
||||
id="tspan1171">relation-list</tspan></tspan></text>
|
||||
<path
|
||||
style="fill:none;stroke:#000000;stroke-width:0.26499999;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#marker1217)"
|
||||
d="M 95.249999,84.577379 107.34524,76.261904"
|
||||
id="path1165"
|
||||
inkscape:connector-curvature="0" />
|
||||
</g>
|
||||
<g
|
||||
transform="translate(21.166667,-64.255953)"
|
||||
id="g1524"
|
||||
class="fragment">
|
||||
<text
|
||||
id="text1211"
|
||||
y="195.70239"
|
||||
x="-14.363099"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;line-height:1.25;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.26458332"
|
||||
xml:space="preserve"><tspan
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#666666;stroke-width:0.26458332"
|
||||
y="195.70239"
|
||||
x="-14.363099"
|
||||
sodipodi:role="line"
|
||||
id="tspan1255">Comparisons (‘=’, ‘<>’, ‘<‘, ‘>’, ‘<=’, ‘>=’) and other </tspan><tspan
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#666666;stroke-width:0.26458332"
|
||||
y="204.52184"
|
||||
x="-14.363099"
|
||||
sodipodi:role="line"
|
||||
id="tspan1263">boolean predicates, combined using AND, OR, and NOT </tspan><tspan
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#666666;stroke-width:0.26458332"
|
||||
y="213.34128"
|
||||
x="-14.363099"
|
||||
sodipodi:role="line"
|
||||
id="tspan1257">(a boolean formula)</tspan></text>
|
||||
<path
|
||||
inkscape:connector-curvature="0"
|
||||
id="path1213"
|
||||
d="m 86.858927,189.88154 -5.367258,-8.31547"
|
||||
style="fill:none;stroke:#000000;stroke-width:0.26499999;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#marker1175)"
|
||||
sodipodi:nodetypes="cc" />
|
||||
</g>
|
||||
<g
|
||||
id="g2074"
|
||||
class="fragment">
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;line-height:1.25;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.26458332"
|
||||
x="19.654758"
|
||||
y="8.3017855"
|
||||
id="text1532"><tspan
|
||||
sodipodi:role="line"
|
||||
x="19.654758"
|
||||
y="8.3017855"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#666666;stroke-width:0.26458332"
|
||||
id="tspan1590">(optional) keyword indicating that the answer </tspan><tspan
|
||||
sodipodi:role="line"
|
||||
x="19.654758"
|
||||
y="17.121229"
|
||||
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7.05555534px;font-family:sans-serif;-inkscape-font-specification:'sans-serif, Normal';font-variant-ligatures:normal;font-variant-caps:normal;font-variant-numeric:normal;font-feature-settings:normal;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#666666;stroke-width:0.26458332"
|
||||
id="tspan1597">should not contain duplicates</tspan></text>
|
||||
<path
|
||||
sodipodi:nodetypes="cc"
|
||||
style="fill:none;stroke:#000000;stroke-width:0.26499999;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker-end:url(#marker1545)"
|
||||
d="m 81.567261,18.733908 4.838099,7.55953"
|
||||
id="path1534"
|
||||
inkscape:connector-curvature="0" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 17 KiB |
BIN
src/teaching/cse-562/2021sp/slide/graphics/slido.png
Normal file
BIN
src/teaching/cse-562/2021sp/slide/graphics/slido.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 402 B |
|
@ -2,37 +2,37 @@
|
|||
font-family: 'News Cycle';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
src: local('News Cycle'), local('NewsCycle'), url(../reveal.js-3.1.0/fonts/9Xe8dq6pQDsPyVH2D3tMQsDdSZkkecOE1hvV7ZHvhyU.ttf) format('truetype');
|
||||
src: local('News Cycle'), local('NewsCycle'), url(../../../slide/reveal.js-3.1.0/fonts/9Xe8dq6pQDsPyVH2D3tMQsDdSZkkecOE1hvV7ZHvhyU.ttf) format('truetype');
|
||||
}
|
||||
@font-face {
|
||||
font-family: 'News Cycle';
|
||||
font-style: normal;
|
||||
font-weight: 700;
|
||||
src: local('News Cycle Bold'), local('NewsCycle-Bold'), url(../reveal.js-3.1.0/fonts/G28Ny31cr5orMqEQy6ljt8BaWKZ57bY3RXgXH6dOjZ0.ttf) format('truetype');
|
||||
src: local('News Cycle Bold'), local('NewsCycle-Bold'), url(../../../slide/reveal.js-3.1.0/fonts/G28Ny31cr5orMqEQy6ljt8BaWKZ57bY3RXgXH6dOjZ0.ttf) format('truetype');
|
||||
}
|
||||
@font-face {
|
||||
font-family: 'Lato';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
src: local('Lato Regular'), local('Lato-Regular'), url(../reveal.js-3.1.0/fonts/1EqTbJWOZQBfhZ0e3RL9uvesZW2xOQ-xsNqO47m55DA.ttf) format('truetype');
|
||||
src: local('Lato Regular'), local('Lato-Regular'), url(../../../slide/reveal.js-3.1.0/fonts/1EqTbJWOZQBfhZ0e3RL9uvesZW2xOQ-xsNqO47m55DA.ttf) format('truetype');
|
||||
}
|
||||
@font-face {
|
||||
font-family: 'Lato';
|
||||
font-style: normal;
|
||||
font-weight: 700;
|
||||
src: local('Lato Bold'), local('Lato-Bold'), url(../reveal.js-3.1.0/fonts/MZ1aViPqjfvZwVD_tzjjkwLUuEpTyoUstqEm5AMlJo4.ttf) format('truetype');
|
||||
src: local('Lato Bold'), local('Lato-Bold'), url(../../../slide/reveal.js-3.1.0/fonts/MZ1aViPqjfvZwVD_tzjjkwLUuEpTyoUstqEm5AMlJo4.ttf) format('truetype');
|
||||
}
|
||||
@font-face {
|
||||
font-family: 'Lato';
|
||||
font-style: italic;
|
||||
font-weight: 400;
|
||||
src: local('Lato Italic'), local('Lato-Italic'), url(../reveal.js-3.1.0/fonts/61V2bQZoWB5DkWAUJStypevvDin1pK8aKteLpeZ5c0A.ttf) format('truetype');
|
||||
src: local('Lato Italic'), local('Lato-Italic'), url(../../../slide/reveal.js-3.1.0/fonts/61V2bQZoWB5DkWAUJStypevvDin1pK8aKteLpeZ5c0A.ttf) format('truetype');
|
||||
}
|
||||
@font-face {
|
||||
font-family: 'Lato';
|
||||
font-style: italic;
|
||||
font-weight: 700;
|
||||
src: local('Lato Bold Italic'), local('Lato-BoldItalic'), url(../reveal.js-3.1.0/fonts/HkF_qI1x_noxlxhrhMQYECZ2oysoEQEeKwjgmXLRnTc.ttf) format('truetype');
|
||||
src: local('Lato Bold Italic'), local('Lato-BoldItalic'), url(../../../slide/reveal.js-3.1.0/fonts/HkF_qI1x_noxlxhrhMQYECZ2oysoEQEeKwjgmXLRnTc.ttf) format('truetype');
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue