Core\Db\Rows
The whole result of a query, read into memory at once. A foreach loop gives its rows one by one.
Returned by
You get a Core\Db\Rows from these methods:
Core\Db\Connection::queryCore\Db\Connection::queryAsCore\Db\Transaction::queryCore\Db\Transaction::queryAs
Members
6 members.
| Member | Signature |
|---|---|
all | all(): array<T> |
first | first(): ?T |
value | value(): mixed |
column | column(int|string $key): array<mixed> |
count | count(): uint |
columns | columns(): array<Core\Db\Column> |
Example apps
These complete apps use this class. You can download and run each one.
- Chat: A chat app with rooms, WebSockets and SQLite. One Novis server sends the pages and runs every connection, with no separate WebSocket server and no library.
- Notes: A small notes app with SQLite, HTML pages, a JSON API, form checks and tests. Download it, run it and start your own app from it.
- Poll: A live poll with SQLite and server-sent events. Every open page shows each new vote at once, with no extra server and no library.
