This is the client CLI-Based Application of a database management system (DBMS) implemented in Java. Server can be found 👉 here.
overview.mp4
This DBMS system was developed by students as part of a class project and should not be considered a fully-functional system.
It is transactional by default, use COMMIT
or ROLLBACK
on change.
- Java Runtime Environment
- Command Line Interface - CLI
- Whatever Operating System
You can download the latest version on release section.
Run: java -jar databaseClient.jar [host ipV4] [port]
Args: The ipv4 and port of the host
Be Aware!
- Syntax are not case-sensitive
- No semicolon at the end of a query
Available comparison operator are
==
,!=
,<=
,>=
,<
and>
. We use=
for affectation like on update!
CREATE TABLE table-name
: objects name like "database" are not allowed to be a table name.INSERT INTO table VALUES val1,val2...
Don't forget toCOMMIT
after insertion, deletion and update orROLLBACK
if needed.
DESC DATABASE
to view all existing relationDESC table-name
to view all field of a relationSELECT * FROM table
SELECT * FROM table WHERE col==value
SELECT col1,col2... FROM table ...
SELECT * FROM table1 JOIN table2 ON id==id ...
SELECT * FROM table1 UNION table2 ...
SELECT * FROM table1 INTERSECTS table2 ...
SELECT * FROM table1 MINUS table2 ...
SELECT * FROM table1 DIVIDED_BY table2 ...
- Sub-query works by using parentheses
eg:SELECT * FROM table1 UNION (SELECT * FROM DIVIDE table2 BY table 3)
UPDATE table SET col=value WHERE col1==value1
DROP TABLE table-name
DELETE FROM table
DELETE FROM table WHERE col=value
EXIT
to stop the client