Minirel_2 - EECS 484 Winter 2011 Project 4 Minirel 2K Query...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Minirel2K: Utilities and Queries Page 1 EECS 484, Winter 2011 Project 4: Minirel 2K Query Processor Due: April 13 at 10:30AM Introduction In this project, you will implement a query processor and some basic utilities for the Minirel2K system. When your query processor is complete, you will have a simple single-user DBMS that accepts a (small) subset of SQL. Basics Once complete, your DBMS will include three executable programs, which you will be able to run from the command line: 1. dbcreate <dbname> This executable creates the database dbname . 2. minirel <dbname> [SQL-file] This executable allows you to interact with the database named dbname by writing (simple) SQL commands. If the optional SQL-file is specified, then the program reads SQL from that file. While industrial-strength DBMSs support concurrent access to data, for the purposes of this assignment, we will assume that there will be at most one minirel process running at a time, so we do not need to worry about concurrency control. 3. dbdestroy <dbname> This program deletes the database dbname. Framework Overview To get your started, we provide a skeleton framework, which consists of a significant quantity of source code, as well as some libraries. Figure 1 gives an overview of the framework. The following is a brief description of each of the main components. Parser: The minirel executable accepts SQL queries and other utility commands. (See the next section for a full description of the supported SQL commands.) We provide a parser, which first parses the input SQL, and then consults the system catalogs to make sure the commands are valid (i.e., the relations and attributes mentioned by the command actually exist in the database.) If the SQL is valid, the parser calls the appropriate query operators and utilities. The parser is implemented for you. Query Optimizer, Operators, and Utilities: This is where you will do most of your work. If the incoming SQL command is valid, the parser calls the appropriate function to process the command: If the command is a utility, the parser calls the appropriate function to process the utility. For this project, you will only be implementing one utility (insert). The function header (Updates::Insert) can be found in the file query.h, and the actual implementation of this function will go in insert.cpp. If the command is a query, the parser first determines if the query is a select query (referencing just one table) or a join query. To execute a select query, the parser calls Operators::Select (in select.cpp). To execute a join query, it calls Operators::Join (in join.cpp). The Operator class definition can be found in query.h. For this assignment, you will implement the insert, select, and join operators.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 12/08/2011 for the course EECS 484 taught by Professor Staff during the Winter '08 term at University of Michigan.

Page1 / 10

Minirel_2 - EECS 484 Winter 2011 Project 4 Minirel 2K Query...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online