assignments for the night
This commit is contained in:
parent
e9e631aa6b
commit
7fe87111fc
1 changed files with 9 additions and 0 deletions
|
@ -8,6 +8,7 @@ db_engine::db_engine(){
|
|||
|
||||
//create a new table in memory
|
||||
//creates a vector
|
||||
//DONE
|
||||
void db_engine::createCmd(string tableName, vector<string> attributes, vector<string> pkeys){
|
||||
string output = "";
|
||||
output += "CREATE TABLE " + tableName + " (";
|
||||
|
@ -52,6 +53,7 @@ void db_engine::createCmd(string tableName, vector<string> attributes, vector<st
|
|||
//}
|
||||
|
||||
//should write cmdList to a .txt file
|
||||
//DONE
|
||||
void db_engine::saveCmd(){
|
||||
ofstream dbCmdFile;
|
||||
dbCmdFile.open("dbCmds.txt", ios_base::app);
|
||||
|
@ -66,36 +68,43 @@ void db_engine::saveCmd(){
|
|||
}
|
||||
|
||||
//display the database
|
||||
//DONE
|
||||
void db_engine::showCmd(string tableName){
|
||||
cmdList.push_back("SHOW " + tableName + "");
|
||||
}
|
||||
|
||||
//add a tuple to a table in the memory
|
||||
//BECCA
|
||||
void db_engine::insertQuery(){
|
||||
//table.push_back();
|
||||
}
|
||||
|
||||
//remove a tuple from a table in the memory
|
||||
//BECCA
|
||||
void db_engine::deleteQuery(){
|
||||
//
|
||||
}
|
||||
|
||||
//search and return one more tuples from a table in the memory
|
||||
//WILLIAM
|
||||
void db_engine::selectQuery(){
|
||||
//
|
||||
}
|
||||
|
||||
//return a subset of attributes (columns)
|
||||
//BRANDON
|
||||
void db_engine::projectQuery(){
|
||||
//
|
||||
}
|
||||
|
||||
//each row in the first table is paired with all the rows in the second table
|
||||
//BRANDON
|
||||
void db_engine::productQuery(){
|
||||
//
|
||||
}
|
||||
|
||||
//true if relations have the same # of attributes and each attribute must be from the same domain
|
||||
//WILLIAM
|
||||
bool db_engine::unionComp(){
|
||||
return false;
|
||||
}
|
||||
|
|
Reference in a new issue