pub fn delete_relationships_by_relation(
conn: &Connection,
namespace: &str,
relation: &str,
) -> Result<(usize, Vec<i64>), AppError>Expand description
Deletes all relationships matching a relation type within a namespace.
Operates in chunks of 1000 to avoid holding long write locks and blocking WAL readers. After deletion, recalculates degree for every affected entity.
Returns (count_deleted, affected_entity_ids).
ยงErrors
Returns Err(AppError::Database) on any rusqlite failure.