Skip to main content

append_edges

Function append_edges 

Source
pub fn append_edges(conn: &Connection, edges: &[GraphEdge]) -> Result<()>
Expand description

Append many edges in a single transaction (INSERT OR IGNORE — duplicates by ID or by the (source, target, relation) unique index are skipped).

Equivalent to calling append_edge per edge, but commits once and reuses one prepared statement, so it scales to hundreds of thousands of edges (e.g. building a citation graph during indexing).