From 660c10b4c0526dfb19309e414841863859fb959c Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Tue, 11 Mar 2014 10:15:36 -0700 Subject: [PATCH] *.ipynb: Use absolute URLs to link to the glossary SWC has a single, global glossary [1], not per-subject glossaries. Because this per-subject branch no longer contains the global glossary, we need to adjust the links to point at an external glossary. Done automatically with: $ sed -i 's|\.\./\.\./gloss.html|https://github.com/swcarpentry/bc/blob/master/gloss.md|g' *.ipynb [1]: https://github.com/swcarpentry/bc/blob/master/gloss.md --- 01-select.ipynb | 16 ++++++++-------- 03-filter.ipynb | 2 +- 05-null.ipynb | 2 +- 06-agg.ipynb | 2 +- 07-join.ipynb | 8 ++++---- 08-create.ipynb | 6 +++--- 09-prog.ipynb | 6 +++--- 7 files changed, 21 insertions(+), 21 deletions(-) diff --git a/01-select.ipynb b/01-select.ipynb index 85f074a..2c14b25 100644 --- a/01-select.ipynb +++ b/01-select.ipynb @@ -72,18 +72,18 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "A [relational database](../../gloss.html#relational-database)\n", + "A [relational database](https://github.com/swcarpentry/bc/blob/master/gloss.md#relational-database)\n", "is a way to store and manipulate information\n", - "that is arranged as [tables](../../gloss.html#table-database).\n", - "Each table has columns (also known as [fields](../../gloss.html#field-database)) which describe the data,\n", - "and rows (also known as [records](../../gloss.html#record-database)) which contain the data.\n", + "that is arranged as [tables](https://github.com/swcarpentry/bc/blob/master/gloss.md#table-database).\n", + "Each table has columns (also known as [fields](https://github.com/swcarpentry/bc/blob/master/gloss.md#field-database)) which describe the data,\n", + "and rows (also known as [records](https://github.com/swcarpentry/bc/blob/master/gloss.md#record-database)) which contain the data.\n", " \n", "When we are using a spreadsheet,\n", "we put formulas into cells to calculate new values based on old ones.\n", "When we are using a database,\n", "we send commands\n", - "(usually called [queries](../../gloss.html#query))\n", - "to a [database manager](../../gloss.html#database-manager):\n", + "(usually called [queries](https://github.com/swcarpentry/bc/blob/master/gloss.md#query))\n", + "to a [database manager](https://github.com/swcarpentry/bc/blob/master/gloss.md#database-manager):\n", "a program that manipulates the database for us.\n", "The database manager does whatever lookups and calculations the query specifies,\n", "returning the results in a tabular form\n", @@ -97,7 +97,7 @@ "> every database manager can import and export data in a variety of formats,\n", "> so it *is* possible to move information from one to another.\n", "\n", - "Queries are written in a language called [SQL](../../gloss.html#sql),\n", + "Queries are written in a language called [SQL](https://github.com/swcarpentry/bc/blob/master/gloss.md#sql),\n", "which stands for \"Structured Query Language\".\n", "SQL provides hundreds of different ways to analyze and recombine data;\n", "we will only look at a handful,\n", @@ -244,7 +244,7 @@ "and the table name in Title Case,\n", "but we don't have to:\n", "as the example below shows,\n", - "SQL is [case insensitive](../../gloss.html#case-insensitive)." + "SQL is [case insensitive](https://github.com/swcarpentry/bc/blob/master/gloss.md#case-insensitive)." ] }, { diff --git a/03-filter.ipynb b/03-filter.ipynb index f06d40e..2b9ceda 100644 --- a/03-filter.ipynb +++ b/03-filter.ipynb @@ -34,7 +34,7 @@ "metadata": {}, "source": [ "One of the most powerful features of a database is\n", - "the ability to [filter](../../gloss.html#filter) data,\n", + "the ability to [filter](https://github.com/swcarpentry/bc/blob/master/gloss.md#filter) data,\n", "i.e.,\n", "to select only those records that match certain criteria.\n", "For example,\n", diff --git a/05-null.ipynb b/05-null.ipynb index 0b0f3c3..6d312a2 100644 --- a/05-null.ipynb +++ b/05-null.ipynb @@ -425,7 +425,7 @@ " What does it actually produce?\n", "\n", "1. Some database designers prefer to use\n", - " a [sentinel value](../../gloss.html#sentinel-value)\n", + " a [sentinel value](https://github.com/swcarpentry/bc/blob/master/gloss.md#sentinel-value)\n", " to mark missing data rather than `null`.\n", " For example,\n", " they will use the date \"0000-00-00\" to mark a missing date,\n", diff --git a/06-agg.ipynb b/06-agg.ipynb index f54e01f..7635399 100644 --- a/06-agg.ipynb +++ b/06-agg.ipynb @@ -87,7 +87,7 @@ "metadata": {}, "source": [ "but to combine them,\n", - "wee must use an [aggregation function](../../gloss.html#aggregation-function)\n", + "wee must use an [aggregation function](https://github.com/swcarpentry/bc/blob/master/gloss.md#aggregation-function)\n", "such as `min` or `max`.\n", "Each of these functions takes a set of records as input,\n", "and produces a single record as output:" diff --git a/07-join.ipynb b/07-join.ipynb index 93761c5..ef816e9 100644 --- a/07-join.ipynb +++ b/07-join.ipynb @@ -115,7 +115,7 @@ "metadata": {}, "source": [ "`join` creates\n", - "the [cross product](../../gloss.html#cross-product)\n", + "the [cross product](https://github.com/swcarpentry/bc/blob/master/gloss.md#cross-product)\n", "of two tables,\n", "i.e.,\n", "it joins each record of one with each record of the other\n", @@ -294,8 +294,8 @@ "We can tell which records from `Site`, `Visited`, and `Survey`\n", "correspond with each other\n", "because those tables contain\n", - "[primary keys](../../gloss.html#primary-key)\n", - "and [foreign keys](../../gloss.html#foreign-key).\n", + "[primary keys](https://github.com/swcarpentry/bc/blob/master/gloss.md#primary-key)\n", + "and [foreign keys](https://github.com/swcarpentry/bc/blob/master/gloss.md#foreign-key).\n", "A primary key is a value,\n", "or combination of values,\n", "that uniquely identifies each record in a table.\n", @@ -371,7 +371,7 @@ "Now that we have seen how joins work,\n", "we can see why the relational model is so useful\n", "and how best to use it.\n", - "The first rule is that every value should be [atomic](../../gloss.html#atomic-value),\n", + "The first rule is that every value should be [atomic](https://github.com/swcarpentry/bc/blob/master/gloss.md#atomic-value),\n", "i.e.,\n", "not contain parts that we might want to work with separately.\n", "We store personal and family names in separate columns instead of putting the entire name in one column\n", diff --git a/08-create.ipynb b/08-create.ipynb index 94da1e9..7ae8a58 100644 --- a/08-create.ipynb +++ b/08-create.ipynb @@ -145,14 +145,14 @@ "and all our queries assume there will be a row in the latter\n", "matching every value in the former.\n", " \n", - "This problem is called [referential integrity](../../gloss.html#referential-integrity):\n", + "This problem is called [referential integrity](https://github.com/swcarpentry/bc/blob/master/gloss.md#referential-integrity):\n", "we need to ensure that all references between tables can always be resolved correctly.\n", "One way to do this is to delete all the records\n", "that use `'lake'` as a foreign key\n", "before deleting the record that uses it as a primary key.\n", "If our database manager supports it,\n", "we can automate this\n", - "using [cascading delete](../../gloss.html#cascading-delete).\n", + "using [cascading delete](https://github.com/swcarpentry/bc/blob/master/gloss.md#cascading-delete).\n", "However,\n", "this technique is outside the scope of this chapter.\n", "\n", @@ -179,7 +179,7 @@ " in `Survey.person`\n", " with the string `'unknown'`.\n", "\n", - "2. One of our colleagues has sent us a [CSV](../../gloss.html#csv) file\n", + "2. One of our colleagues has sent us a [CSV](https://github.com/swcarpentry/bc/blob/master/gloss.md#csv) file\n", " containing temperature readings by Robert Olmstead,\n", " which is formatted like this:\n", "\n", diff --git a/09-prog.ipynb b/09-prog.ipynb index 63461ba..4d14368 100644 --- a/09-prog.ipynb +++ b/09-prog.ipynb @@ -91,7 +91,7 @@ "all we need to specify is the name of the database file.\n", "Other systems may require us to provide a username and password as well.\n", "Line 3 then uses this connection to create\n", - "a [cursor](../../gloss.html#cursor);\n", + "a [cursor](https://github.com/swcarpentry/bc/blob/master/gloss.md#cursor);\n", "just like the cursor in an editor,\n", "its role is to keep track of where we are in the database.\n", "\n", @@ -187,7 +187,7 @@ "If we execute this,\n", "it will erase one of the tables in our database.\n", " \n", - "This is called an [SQL injection attack](../../gloss.html#sql-injection-attack),\n", + "This is called an [SQL injection attack](https://github.com/swcarpentry/bc/blob/master/gloss.md#sql-injection-attack),\n", "and it has been used to attack thousands of programs over the years.\n", "In particular,\n", "many web sites that take data from users insert values directly into queries\n", @@ -197,7 +197,7 @@ "the safest way to deal with this threat is\n", "to replace characters like quotes with their escaped equivalents,\n", "so that we can safely put whatever the user gives us inside a string.\n", - "We can do this by using a [prepared statement](../../gloss.html#prepared-statement)\n", + "We can do this by using a [prepared statement](https://github.com/swcarpentry/bc/blob/master/gloss.md#prepared-statement)\n", "instead of formatting our statements as strings.\n", "Here's what our example program looks like if we do this:" ] -- 2.26.2