# Void vs Delete in Molecule

#### Void

**Meaning**\
Marks a trade as voided (canceled) as of a specified date.

**Purpose**\
Void is used when a trade was valid historically but should no longer continue going forward.

**Key Characteristics**

* Preserves **historical valuation data** up to the void as-of date
* Stops **future valuations** after the void date
* Maintains a full **audit trail**
* Voided trades remain visible when *“Show deleted trades”* is enabled
* Yesterday’s valuation row is typically the last relevant row for reporting

**When to use Void**

* A legitimately booked trade is later canceled
* Regulatory or audit requirements require valuation history to be retained
* You need historical P\&L visibility but no future exposure

***

#### Delete

**Meaning**\
Completely removes the trade and all associated valuation data.

**Purpose**\
Delete is used when a trade should be treated as if it never existed.

**Key Characteristics**

* Removes **all valuation history**
* Excludes the trade entirely from reporting and settlements
* Deleted trades are only visible when *“Show deleted trades”* is enabled

**When to use Delete**

* Trades booked in error
* Duplicate or test trades
* Trades with incorrect lifecycle data (e.g., invalid trade dates)

***

#### Void vs Delete: Quick Comparison

| Feature                       | Void                                       | Delete |
| ----------------------------- | ------------------------------------------ | ------ |
| Keeps valuation history       | ✅ Yes                                      | ❌ No   |
| Stops future valuation        | ✅ Yes, except when trade\_date > void date | ✅ Yes  |
| Removes trade entirely        | ❌ No                                       | ✅ Yes  |
| Supports audit trail          | ✅ Yes                                      | ❌ No   |
| Suitable for erroneous trades | ❌ No                                       | ✅ Yes  |

***

#### Best Practice Guidance

* Use **Void** when the trade was once valid and needs to be canceled going forward.
* Use **Delete** when the trade should not exist in the system at all.
* Choosing the correct action ensures accurate valuations, settlements, and clean month-end reporting.
