# GetTaxonomyNodeAssignments

## Overview

GetTaxonomyNodeAssignments retrieves item assignments for a given taxonomy node. Used as a guard check before node deletion to ensure no items are classified under the node being removed.

## Business Rules

- Searches ItemTaxonomyAssignment table for records with taxonomyNodeId matching the given node ID
- Returns all matching assignment records as an array
- Returns an empty array if the node has no item assignments

## Process Flow

```mermaid
flowchart TD
    A[Receive taxonomyNodeId] --> B[SELECT from ItemTaxonomyAssignment where taxonomyNodeId = input]
    B --> C{Assignments found?}
    C -->|Yes| D[Return assignment records]
    C -->|No| E[Return empty array]
```

## External Dependencies

- None

## Error Scenarios

- **NO_ASSIGNMENTS**: No item assignments exist for the given node — caller receives empty array

## Test Cases

- returns assignments when found
- returns empty array when no assignments
