Row¶
Immutable snapshot of one fetched row. Safe to hold across fetches, safe to send across actors.
Typed accessors raise error on both out-of-range index AND type mismatch.
Constructors¶
create¶
Parameters¶
Returns¶
- Row val^
Public Functions¶
column¶
Polymorphic access. Raises error on out-of-range index.
Parameters¶
- i: ColIndex val
Returns¶
- SqlValue val ?
int¶
Read column as I64. Accepts any integer type, widening to I64. Raises error on type mismatch or out of range.
Parameters¶
- i: ColIndex val
Returns¶
float¶
Read column as F64. Raises error on type mismatch or out of range.
Parameters¶
- i: ColIndex val
Returns¶
text¶
Read column as String val. Raises error on type mismatch or out of range.
Parameters¶
- i: ColIndex val
Returns¶
bool¶
Read column as Bool. Raises error on type mismatch or out of range.
Accepts SqlBool, any integer type (0=false, nonzero=true), and SqlText ("1"/"0"/"t"/"f"/"true"/"false") to handle drivers that report boolean columns as SMALLINT or CHAR (e.g., psqlODBC with BoolsAsChar=Yes).
Parameters¶
- i: ColIndex val
Returns¶
date¶
Read column as SqlDate. Raises error on type mismatch or out of range.
Parameters¶
- i: ColIndex val
Returns¶
time¶
Read column as SqlTime. Raises error on type mismatch or out of range.
Parameters¶
- i: ColIndex val
Returns¶
timestamp¶
Read column as SqlTimestamp. Raises error on type mismatch or out of range.
Parameters¶
- i: ColIndex val
Returns¶
- (SqlTimestamp val | SqlNull val) ?
decimal¶
Read column as SqlDecimal. Raises error on type mismatch or out of range.
Parameters¶
- i: ColIndex val
Returns¶
- (SqlDecimal val | SqlNull val) ?
is_null¶
True if column value is SQL NULL. Raises error on out of range.
Parameters¶
- i: ColIndex val
Returns¶
- Bool val ?
size¶
Number of columns in the row.
Returns¶
- USize val