Drop All - Really means "ALL" - Is this a mistake?

Reading the docs:

GSQL> drop all
Delete the current graph and all its associated jobs and queries

In interpret this as dropping only 1 our of n graphs. I created 3 graphs:

  • GraphOne
  • GraphTwo
  • GraphThree

then ran these commands and got the following result.

GSQL > USE GRAPH GraphOne
Using graph 'GraphOne'
GSQL > drop all
Dropping all, about 1 minute ...
Abort all active loading jobs
Try to abort all loading jobs on graph GraphOne, it may take a while ...
[ABORT_SUCCESS] No active Loading Job to abort.
Try to abort all loading jobs on graph GraphTwo, it may take a while ...
[ABORT_SUCCESS] No active Loading Job to abort.
Try to abort all loading jobs on graph GraphThree, it may take a while ...
[ABORT_SUCCESS] No active Loading Job to abort.

Shutdown restpp gse gpe ...
Graph store /home/tigerghraph/data/tigergraph/gstore/0/ has been cleared!
Everything is dropped.
GSQL >

It dropped all graphs where I was expecting to drop only “GraphOne”.

Is this an error in the docs? Could lead to a really bad day…

Please let me know. Thank you.

Hi this is a document bug, I have reported to our doc team. Thank you.
To drop a graph, try

use global
drop GraphOne

The current “drop all” seems ignore the “use graph xxx” context, and drop the entire catalog.

Hi George,
According to the GSQL cheat sheet, DROP ALL erases all graph and job definitions, and clears graph store. So, all indeed means all.

USER GRAPH sets the context for work (i.e. when you refer to a vertex or query, the GSQL client will know where to look for that object), but it does not restrict the scope of DROP ALL to that graph. See @mingxiwu’s comment above how to drop a single graph. (Note: you will need to drop loading jobs and queries first, before you can drop the schema).

George,
We found the one reference that seems to have an incorrect statement:
https://docs.tigergraph.com/intro/gsql-102/get-set#cheatsheet

All the other references to DROP ALL (https://docs.tigergraph.com/dev/gsql-ref/ddl-and-loading/running-a-loading-job#drop-all, etc.) seem to be correct. Thanks.