This commit finalizes the complex querying logic:
- **Refactor `GetAll` (sqlite.go):** Reworks the internal logic to ensure the total number of matching records (`totalCount`) is calculated via a separate COUNT query *before* applying LIMIT/OFFSET.
- **Corrected Pagination:** Adds an explicit check in `GetAll` to return an empty `items` list when `limit=0`, while still reporting the correct `totalCount`.
- **API Handler Update:** Consumes the accurate `totalCount` returned by the Store layer and includes it in the final API response under the `totalItems` field.
This commit introduces the initial structure for the data platform, including:
- **Core Structure:** Setup of basic Go modules, environment, and project layers (cmd, internal, pkg).
- **SQLite Store:** Implements data persistence using SQLite, including schema initialization (collections/records).
- **CRUD Operations:** Full C.R.U.D. logic for records within collections.
- **Dynamic Querying:** Implements advanced query features over JSON data:
- **Filtering:** Dynamic filters (eq, gt, lt, etc.) on JSON fields using SQL casting (`CAST(... AS REAL)`).
- **Pagination:** Support for `limit` and `offset` query parameters.
- **Sorting:** Dynamic sorting based on JSON fields (`orderBy=field` or `orderBy=-field`).