Commands
Here's a list of all the available commands in the database
Schema and core operations.
!help
Displays all commands info.
!quit
Quits the CLI. Aliases: !q
, :q
, :quit
!create_schema
Creates a new schema
Syntax
!create_schema <schema_name> <schema_JSON>;
// example:
!create_schema studentinfo {
"name": "string",
"age": "number"
};
!drop_schema
Drops an existing schema.
Syntax
!drop_schema <schema_name>;
// example:
!drop_schema studentinfo;
!display_schema
Displays data under an schema.
Syntax
!display_schema <schema_name>;
// example:
!display_schema studeinfo;
!load_cache
Loads all the existing data into cache. This is optional and suggested only when large operations have to be performed.
Data related commands
insert
Adds data to an schema with respect to provided ID
Syntax
insert <schema_name> <id> [data_JSON];
// example:
insert studentinfo 1; // app will ask for further data
insert studentinfo 1 {
"name": "sarthak",
"age": 19
};
select
Fetch data from the cache or the storage
Syntax
select <schema_name> <id>;
// example:
select studentinfo 1;