<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Databases and MySQL on kodkod | Intro Course</title><link>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/</link><description>Recent content in Databases and MySQL on kodkod | Intro Course</description><generator>Hugo</generator><language>en</language><copyright>מבואות קודקוד</copyright><atom:link href="https://intro-kodkod-6.nm-ambition.com/en/docs/databases/index.xml" rel="self" type="application/rss+xml"/><item><title>A Database and Setting Up MySQL: Tables, Keys, Docker and a Driver</title><link>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/01-what-is-a-database/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/01-what-is-a-database/</guid><description>&lt;h2 id="in-this-lesson"&gt;In this lesson&lt;/h2&gt;
&lt;p&gt;This lesson is built from two chapters, in the same order as the slides:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Chapter 1&lt;/strong&gt; — what a Database is: table, row, column, Primary Key and data types&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Chapter 2&lt;/strong&gt; — setting up MySQL: Docker, Database Client and a Driver&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id="chapter-1-what-a-database-is--table-row-column-primary-key-and-data-types"&gt;Chapter 1: What a Database Is — Table, Row, Column, Primary Key and Data Types&lt;/h2&gt;
&lt;h3 id="what-will-we-learn"&gt;What will we learn?&lt;/h3&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Why&lt;/strong&gt; you need a Database.&lt;/li&gt;
&lt;li&gt;What a &lt;strong&gt;Relational Database&lt;/strong&gt; is.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Table&lt;/strong&gt;, &lt;strong&gt;Row&lt;/strong&gt;, &lt;strong&gt;Column&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Primary Key&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Basic &lt;strong&gt;Data Types&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;


&lt;div class="teach-box teach-box-tip"&gt;
 &lt;div class="teach-box-title"&gt;What we will not learn here (on purpose)&lt;/div&gt;
 &lt;div class="teach-box-body"&gt;
&lt;p&gt;Here we learn &lt;strong&gt;only the basics needed for CRUD&lt;/strong&gt;: a connection, one table, and creating, reading, updating and deleting. We will &lt;strong&gt;not&lt;/strong&gt; learn JOIN, GROUP BY, HAVING, Sub-Queries, advanced normalization, indexes or Stored Procedures. You will learn those in depth later in the track.&lt;/p&gt;</description></item><item><title>Connecting, a Table and Inserting Data: Connection, CREATE TABLE and INSERT</title><link>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/03-open-test-close-connection/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/03-open-test-close-connection/</guid><description>&lt;h2 id="in-this-lesson"&gt;In this lesson&lt;/h2&gt;
&lt;p&gt;This lesson is built from two chapters, in the same order as the slides:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Chapter 1&lt;/strong&gt; — opening a Connection, checking that the connection works and closing it properly&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Chapter 2&lt;/strong&gt; — basic SQL: CREATE TABLE and INSERT&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id="chapter-1-opening-a-connection-checking-that-the-connection-works-and-closing-it-properly"&gt;Chapter 1: Opening a Connection, Checking That the Connection Works and Closing It Properly&lt;/h2&gt;
&lt;h3 id="what-will-we-learn"&gt;What will we learn?&lt;/h3&gt;
&lt;p&gt;The &lt;strong&gt;life cycle&lt;/strong&gt; of all work with a database:&lt;/p&gt;</description></item><item><title>Basic SQL: SELECT, WHERE by id and Simple Filtering</title><link>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/02-select-where/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/02-select-where/</guid><description>&lt;h2 id="what-will-we-learn"&gt;What will we learn?&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;&lt;code&gt;SELECT&lt;/code&gt;&lt;/strong&gt; = the &lt;strong&gt;R&lt;/strong&gt;ead of CRUD: reading data from a table.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;All the rows&lt;/strong&gt;: &lt;code&gt;SELECT * FROM students&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Chosen columns&lt;/strong&gt;: &lt;code&gt;SELECT name, email FROM students&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;One row by id&lt;/strong&gt;: &lt;code&gt;SELECT ... WHERE id = 2&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Simple filtering&lt;/strong&gt; with &lt;code&gt;WHERE&lt;/code&gt; and conditions.&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Sorting&lt;/strong&gt; with &lt;code&gt;ORDER BY&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id="why-do-we-need-this"&gt;Why do we need this?&lt;/h2&gt;
&lt;p&gt;The two most important queries in every API:&lt;/p&gt;</description></item><item><title>Running a Query from Python: execute, Parameters, commit and fetch</title><link>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/03-queries-from-python/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/03-queries-from-python/</guid><description>&lt;h2 id="what-will-we-learn"&gt;What will we learn?&lt;/h2&gt;
&lt;p&gt;Until now we wrote &amp;ldquo;manual&amp;rdquo; SQL in Database Client. Now we connect it to code, following the path the syllabus emphasizes:&lt;/p&gt;</description></item><item><title>Updating and Deleting: UPDATE and DELETE by id — from SQL and from Python</title><link>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/01-update/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/01-update/</guid><description>&lt;h2 id="in-this-lesson"&gt;In this lesson&lt;/h2&gt;
&lt;p&gt;This lesson is built from two chapters, in the same order as the slides:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Chapter 1&lt;/strong&gt; — UPDATE by id: updating a record from SQL and from Python&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Chapter 2&lt;/strong&gt; — DELETE by id: deleting a record from SQL and from Python&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id="chapter-1-update-by-id--updating-a-record-from-sql-and-from-python"&gt;Chapter 1: UPDATE by id — Updating a Record from SQL and from Python&lt;/h2&gt;
&lt;h3 id="what-will-we-learn"&gt;What will we learn?&lt;/h3&gt;
&lt;p&gt;&lt;strong&gt;&lt;code&gt;UPDATE&lt;/code&gt;&lt;/strong&gt; = the &lt;strong&gt;U&lt;/strong&gt; of CRUD: changing an &lt;strong&gt;existing&lt;/strong&gt; record.&lt;/p&gt;</description></item><item><title>Full CRUD from Python: a Complete db.py Module and Testing All Four Actions</title><link>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/04-full-crud-module/</link><pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate><guid>https://intro-kodkod-6.nm-ambition.com/en/docs/databases/04-full-crud-module/</guid><description>&lt;h2 id="what-will-we-learn"&gt;What will we learn?&lt;/h2&gt;
&lt;p&gt;At the end of this lesson, as the syllabus defines, we have &lt;strong&gt;full CRUD from Python&lt;/strong&gt;. The lesson assembles all the parts from the previous lessons into &lt;strong&gt;one module&lt;/strong&gt;, &lt;code&gt;db.py&lt;/code&gt;, and tests it from end to end.&lt;/p&gt;</description></item></channel></rss>