Skip to content

SanchitaJain4/5300-Peacock

 
 

Repository files navigation

5300-Peacock

CPSC5300/4300 at Seattle U, Spring 2022 Group Members: Alex C. L. & Zhicong Zeng

Usage (argument is database directory):

$ ./sql5300 ~/cpsc5300/data

Tags

  • Milestone1 is playing around with the AST returned by the HyLine parser and general setup of the command loop.
  • Milestone2 Implement a rudimentary storage engine. Implemented the basic functions needed for HeapTable with two data types: integer and text.
  • Milestone3 Implement functions to create tables, drop tables, show tables and show columns.
  • Milestone4 Implement functions to create, show, and drop indices

Unit Tests

There are some tests for SlottedPage and HeapTable. They can be invoked from the SQL prompt:

SQL> test

Be aware that failed tests may leave garbage Berkeley DB files lingering in your data directory. If you don't care about any data in there, you are advised to just delete them all after a failed test.

$ rm -f data/*

There are alse some tests for SQLExec.cpp. They can be invoked from the SQL prompt:

SQL> test2    or    SQL> test table
SQL> test3    or    SQL> test index

Valgrind (Linux)

To run valgrind (files must be compiled with -ggdb):

$ valgrind --leak-check=full --suppressions=valgrind.supp ./sql5300 ~/cpsc5300/data

Note that we've added suppression for the known issues with the Berkeley DB library vis-à-vis valgrind.

Memory Leaks

There is no memory leak in this project. Still has many memory leaks in SQLParser.cpp.

Handoff Video

https://seattleu.instructuremedia.com/embed/88731152-3ca6-467a-9add-1c6ea9d4da5f

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C++ 98.6%
  • Makefile 1.2%
  • C 0.2%