Skip to content

Commit f5293b6

Browse files
committed
formatting fixes
1 parent b15608c commit f5293b6

1 file changed

Lines changed: 28 additions & 12 deletions

File tree

README.md

Lines changed: 28 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# SQL Bear Organizer
22

3-
[Timothy Treadwell](http://en.wikipedia.org/wiki/Timothy_Treadwell) has a lot on his plate protecting the bears of the Katmai National Park in Alaska. Help him keep track of all of his bear friends using SQL.
3+
[Timothy Treadwell](http://en.wikipedia.org/wiki/Timothy_Treadwell) has a lot on
4+
his plate protecting the bears of the Katmai National Park in Alaska. Help him
5+
keep track of all of his bear friends using SQL.
46

57
![timothy-treadwell](http://m2.paperblog.com/i/74/746121/lagghiacciante-morte-delluomo-grizzly-sbranat-L-rr7aep.jpeg)
68

@@ -12,7 +14,8 @@
1214

1315
## Lab Structure
1416

15-
This lab might seem a bit different than what you've seen before. Take a look at the file structure:
17+
This lab might seem a bit different than what you've seen before. Take a look at
18+
the file structure:
1619

1720
```bash
1821
├── Gemfile
@@ -44,15 +47,22 @@ before do
4447
@sql_runner.execute_create_file
4548
end
4649
```
50+
4751
Before each test two important things happen.
4852

49-
First, a new in-memory database is created. Why do we do this? Let's say we run our tests and they add ten items to our database. If we did not use an in-memory store, those would be in there forever. This way our database gets thrown out after every running of the tests. You can learn more about in-memory databases [here](https://www.sqlite.org/inmemorydb.html).
53+
First, a new in-memory database is created. Why do we do this? Let's say we run
54+
our tests and they add ten items to our database. If we did not use an in-memory
55+
store, those would be in there forever. This way our database gets thrown out
56+
after every running of the tests. You can learn more about in-memory databases
57+
[here](https://www.sqlite.org/inmemorydb.html).
5058

51-
Next, a new `SqlRunner` class is created. The `SqlRunner` class lives in your `bin` directory and was created to help connect to the database.
59+
Next, a new `SqlRunner` class is created. The `SqlRunner` class lives in your
60+
`bin` directory and was created to help connect to the database.
5261

5362
## Part 1: `CREATE TABLE`
5463

55-
Get the tests in `spec/create_spec.rb` to pass. Your `CREATE` statement should look something like this:
64+
Get the tests in `spec/create_spec.rb` to pass. Your `CREATE` statement should
65+
look something like this:
5666

5767
```sql
5868
CREATE TABLE bears (
@@ -98,11 +108,14 @@ Your columns should be the following types:
98108
</tr>
99109
</table>
100110

101-
Read about [SQLite3 Datatypes](https://www.sqlite.org/datatype3.html) to determine what your insert values are going to be. Be sure to pay attention to how booleans are expressed in SQLite3.
111+
Read about [SQLite3 Datatypes](https://www.sqlite.org/datatype3.html) to
112+
determine what your insert values are going to be. Be sure to pay attention to
113+
how booleans are expressed in SQLite3.
102114

103115
## Part 2: `INSERT`
104116

105-
Get the tests in `spec/insert_spec.rb` to pass. Input the following 8 bears (you can make up details about them, but make sex either 'M' or 'F'):
117+
Get the tests in `spec/insert_spec.rb` to pass. Input the following 8 bears (you
118+
can make up details about them, but make sex either 'M' or 'F'):
106119

107120
* Mr. Chocolate
108121
* Rowdy
@@ -111,17 +124,20 @@ Get the tests in `spec/insert_spec.rb` to pass. Input the following 8 bears (you
111124
* Melissa
112125
* Grinch
113126
* Wendy
114-
* unnamed (the bear that killed Tim didn't have a name; refer back to how to create a record that doesn't have one value)
127+
* unnamed (the bear that killed Tim didn't have a name; refer back to how to
128+
create a record that doesn't have one value)
115129

116130
## Part 3: `SELECT`
117131

118-
Get the tests in `spec/select_spec.rb` to pass. Note that for this section, the database will be seeded with external data from the `lib/seed.sql` file so don't expect it to reflect the data you added above. Note: Since it's a Ruby file, write your queries as strings in the `lib/sql_queries.rb`.
132+
Get the tests in `spec/select_spec.rb` to pass. Note that for this section, the
133+
database will be seeded with external data from the `lib/seed.sql` file so don't
134+
expect it to reflect the data you added above. Note: Since it's a Ruby file,
135+
write your queries as strings in the `lib/sql_queries.rb`.
119136

120-
You may be expected to use SQL statements that you're not particularly familiar with. Make sure you use the resources and Google to find the right statements.
137+
You may be expected to use SQL statements that you're not particularly familiar
138+
with. Make sure you use the resources and Google to find the right statements.
121139

122140
## Resources
123141

124142
[SQL Datatypes](https://www.sqlite.org/datatype3.html)
125143
[SQL GROUP BY](https://www.sqlite.org/lang_select.html#resultset)
126-
127-

0 commit comments

Comments
 (0)