Skip to content

A CLI based DBMS made using C++. It supports basic SQL Queries.

Notifications You must be signed in to change notification settings

mrpandya/DBMS_from_scratch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DBMS made from SCRATCH

This is a SQL based Database Management System. This DBMS works IMPORT, SELECT, INSERT, DELETE queries.

This DBMS has a fixed schema and the SQL queries can be run on the Command Line Interface.



Screenshots:

ss1 ss2 ss3 ss4 ss5

How to use:

  • Clone the repo :
$ git clone https://github.com/mrpandya/DBMS_from_scratch.git
  • Go to the repo :
$ cd DBMS_from_scratch
  • To compile :

GNU G++ compiler for C++ required

$ g++ -o driver driver.cpp
  • To execute :

Compiled version for linux version has already been added. You can directly run the executable file without compiling

$ ./driver



Schema

Column Name Data Type
id INT
username STRING
email STRING
password STRING



Syntax

IMPORT Query

Import <file_name>.csv;

SELECT Query

 Select * from <table_name> [Where] [column_name] [operation] [value];
  • OPTION

     WHERE => It can be used only on any one column.
     OPERATION => Valid operations are {=, !=, >, <, <=, >=}
    

INSERT Query

 Insert into <table_name> values (data...);
  • DESCRIPTION

     DATA => It is comma separated string of the data to be inserted. DO NOT leave a space in the paranthesis.
    

DELETE Query

 Delete from <table_name> [Where] [column_name] [operation] [value];
  • OPTION

     WHERE => It can be used only on any one column.
     OPERATION => Valid operations are {=, !=, >, <, <=, >=}
    



The following code has been tested and executed on Linux.

This project still has scope of development, so you can also contribute to this Project as follows:

  • Fork this Repository.
  • Clone your Fork on a different branch:
    • git clone -b <name-of-branch> https://github.com/mrpandya/DBMS_from_scratch.git
  • After adding any feature:
    • Goto your fork and create a pull request.
    • Your modifications will be tested and the changes will be merged.

Developed with ❤️ by Manan Pandya .

About

A CLI based DBMS made using C++. It supports basic SQL Queries.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages