With the View Subgraphs function, you can run a FIND SHORTEST | ALL PATH or a
GET SUBGRAPH statement on the Console page and then view the result on the Explore page.
Studio of v3.2.3 supports this function. To update the version, see Check updates.
To use the View Subgraphs function, you must do a check of these:
- The version of Studio is v3.2.3 or later.
- Studio is connected to NebulaGraph.
- A dataset exists in the database. In the example of this article, the basketballplayer dataset is used. For more information, see Import data.
Users can view subgraphs online in Studio.
To query the paths or subgraph on the Console page and then view them on the Explore page, follow these steps:
In the navigation bar, click the Console tab.
In the Current Graph Space dropdown list, choose a graph space name. In this example, baskteballplayer is chosen.
In the input box, enter a
FIND SHORTEST PATH,
FIND ALL PATH, or
GET SUBGRAPHstatement and click Run .
Here is an nGQL statement example.
nebula> FIND ALL PATH FROM "player114" to "player100" OVER follow YIELD path AS p;
FIND ALL PATHfor example, query the path information as shown in this figure.
Click the View Subgraphs button.
(Optional) If some data exists on the board of Explore, choose a method to insert data:
- Incremental Insertion: Click this button to add the result to the existing data on the board.
- Insert After Clear: Click this button to clear the existing data from the board and then add the data to the board.
When the data is inserted, you can view the visualized representation of the paths. Operations such as expanding vertices, moving the canvas, modifying the color and icon of the vertices, and displaying the properties of the vertices and edges on the page are supported.
Next to do¶
On the Explore page, you can expand the graph to explore and analyze graph data.