# Storing

## Storing fixed amounts

&#x20;If you need to store or transmit a fixed value we recommend that you store the value as two discrete numbers:

* &#x20;minorUnits
* scale

Both values should be stored as integers. If storing in a database minorUnits may need to be stored in a large int type.

Storing the value using this technique guarantees no precision loss when storing, transmitting or retrieving Fixed decimal values.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://fixed.onepub.dev/storing.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
