• Stars
    star
    1,567
  • Rank 29,877 (Top 0.6 %)
  • Language
    JavaScript
  • License
    MIT License
  • Created almost 7 years ago
  • Updated 11 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Inspired by @veltman's command-line mystery, use SQL to research clues and find out whodunit!

SQL Murder Mystery

Illustration of a detective looking at evidence

There's been a Murder in SQL City! The SQL Murder Mystery is designed to be both a self-directed lesson to learn SQL concepts and commands and a fun game for experienced SQL users to solve an intriguing crime.

If you just want to solve the mystery, go to mystery.knightlab.com. If you're new to SQL, you may want to start at our walkthrough. It won't teach you everything about SQL, but it should teach you all that you need to solve the mystery.

What Else is Here?

Before we built the web-based version, we designed this for people to download and solve on their own computer. If you're interested in that, read on.

What you need to solve on your own computer

  • sql-murder-mystery.db: This SQLite database file contains all the data that you will be working with.
  • prompt: Depending on your experience level with SQL, find the prompt in either the prompt_experienced file or the prompt_beginner file.
  • reference: This is a crash course on SQL concepts and commands.
  • a SQLite environment of your choice: For beginners, we recommend using SQLiteStudio, which is a good graphical interface to use to inspect your data and write queries.

Getting Started

  • For SQL beginners: start with the reference, read the prompt_beginner file, then get started by installing SQLiteStudio and loading the db file. If you get stuck at any point, feel free to refer back to the reference, or file a GitHub issue so we can know where our instructions need to be improved.

  • For experienced SQL users: read the prompt_experienced file, then download the sql-murder-mystery.db file and use a SQL environment of your choice to solve the mystery. You can use the reference to refresh your memory of SQL. Try to complete the activity all within your SQL environment (without writing down notes)!

Checking the Solution

Write the following queries in your SQL environment to check whether you've found the right murderer:

INSERT INTO solution VALUES (1, "Insert the name of the person you found here");

SELECT value FROM solution;

Authors

Inspiration

This murder mystery was inspired by a crime in the neighboring Terminal City.

Copyright and License

Original code for this project is released under the MIT License.

Original text and other content is released under Creative Commons CC BY-SA 4.0.

SQL query custom web components used here were adapted from code created and released to the public domain by Zi Chong Kao, creator of Select Star SQL.

Detective image by rambleron used under Vecteezy's free license.

More Repositories

1

TimelineJS

TimelineJS: A Storytelling Timeline built in JavaScript.
JavaScript
8,859
star
2

TimelineJS3

TimelineJS v3: A Storytelling Timeline built in JavaScript. http://timeline.knightlab.com
JavaScript
2,867
star
3

juxtapose

JuxtaposeJS is a JavaScript library for making before/after image sliders
JavaScript
811
star
4

TimelineJS-Wordpress-Plugin

A simple shortcode plugin to add the Timeline to Wordpress
JavaScript
207
star
5

soundcite

Making Inline Audio Easy and Seamless
HTML
193
star
6

StoryMapJS

Maps that tell stories.
JavaScript
162
star
7

storyline

Tell the story behind the numbers.
JavaScript
123
star
8

SceneVR

A Tool for Creating Shareable, Embeddable WebVR Stories
JavaScript
39
star
9

twxplorer

HTML
35
star
10

Picture-Story

Bootstrap theme for photo layouts. For use in Medill photojournalism classes.
HTML
27
star
11

bonfire

Automated curation of tweeted content from your Twitterverse
Python
16
star
12

InstaTimeline

Collaborative Innovation Class Project
JavaScript
14
star
13

BootstrapPictureStory

Bootstrap theme for photo layouts. For use in Medill photojournalism classes.
CSS
12
star
14

how-we-work

A collection of "how we work" resources, including our code style manuals
JavaScript
10
star
15

SensorGrid

C++
10
star
16

SensorGridAPI

Web API and dashboard for SensorGrid
JavaScript
10
star
17

VRJournFieldGuide

A guide to learning about VR as it pertains to journalistic applications
HTML
9
star
18

socialvideo-prototype

Summer 2017 Student Project
JavaScript
9
star
19

soundcite-wordpress-plugin

Making it easier to use SoundciteJS with Wordpress
PHP
8
star
20

learncms

Learn.Knightlab.com CMS version
HTML
8
star
21

pullquote

Pullquote can instantly create a picture quote from any user selected text on a website.
JavaScript
8
star
22

frontend-buildkit

This is the basic starter kit for Knight Lab frontend projects
JavaScript
7
star
23

timeline-addon

Experimenting with a Google Docs add-on to manage TimelineJS spreadsheets
HTML
7
star
24

VideoSliderJS

SND Makes project looking at making video more "webby"
JavaScript
7
star
25

fablib

Package for Fabric deployments
Python
5
star
26

neighborhood-buzz

Python
5
star
27

reveal.js-template

A template for creating Knight Lab-themed reveal.js slides.
JavaScript
5
star
28

ComingUP

Collaborative Innovation Class Project
JavaScript
4
star
29

circlethething

tater
JavaScript
4
star
30

videojam

A new start for Project VideoJAM
JavaScript
4
star
31

tapestry

A WordPress plugin for organizing posts into a narrative arc.
JavaScript
4
star
32

blueline

An asset generator and style guide for Knight Lab websites
HTML
4
star
33

openlab.knightlab.com

HTML
4
star
34

learn-prototype

a (probably throw-away) place to start working out UX practices for the new learn.knightlab.com
HTML
4
star
35

fao-explorer

Tools to better understand the UN FAO API
JavaScript
4
star
36

untangled-research

A microsite organizing research on use of social network analysis in journalism. Read at untangled.knightlab.com
Python
4
star
37

device-lab-runbook

A quick guide to getting started with our devices!
HTML
3
star
38

TV-tools

Tools used by Knight Lab for broadcast television related projects
Arduino
3
star
39

MusicRecs

Collaborative Innovation Class Project
Python
3
star
40

django-project-template

Project template for creating Knight Lab Django projects. Use with the settings flag for django-admin.py startproject.
Python
3
star
41

piquote

JavaScript
3
star
42

oembed-server

A system to take oembed requests for KnightLab's embeddable tools.
HTML
3
star
43

Collective

A gamified experience about managing resources with augmented reality
C#
3
star
44

studio-documenters

Explorations for the Documenters.org project
Jupyter Notebook
3
star
45

GPSKit

A collection of useful things we have learned about working with GPS hardware and data
Python
3
star
46

iphone-exquisite-corpse

Let's just mess around with an iphone app to learn some more about XCode and app development
Swift
2
star
47

Class-2016F-MadCast

Podcast Discovery project in the Knight Lab class.
JavaScript
2
star
48

openlabhours

CSS
2
star
49

studio-talk-to-data

Initial work for Knight Lab W18 "Talking to Data" team
Python
1
star
50

chicago-justice

Chicago Justice Project
Python
1
star
51

TarbellGUI

Desktop application for managing your Tarbell
Python
1
star
52

git-deploy

Ansible based deployment script implemented as a git subcommand
Python
1
star
53

KnightLab_SDConfig

Read config files from the SD card of an Adalogger
C++
1
star
54

SensorGridRouter

LoRa routing for the SensorGrid project
C++
1
star
55

KnightLab_GPS

Timer interrupt setup for Adafruit GPS on Feather 32u4 and M0
C++
1
star
56

weatherbot

Code developed with Associated Press and El Vocero to automatically generate stories for weather emergencies.
Python
1
star
57

DisparityMap

Javascript based map showing racial disparity in Chicago.
JavaScript
1
star
58

scenevr-author

A web-based authoring tool for Scene VR
HTML
1
star