[API reference](https://evolu.dev/docs/api-reference) › [@evolu/sqlite-wasm](https://evolu.dev/docs/api-reference/sqlite-wasm) › [c-api](https://evolu.dev/docs/api-reference/sqlite-wasm/c-api) › sqlite3\_vtab\_rhs\_value

```ts
function sqlite3_vtab_rhs_value(
  deps: SqliteWasmDep,
): (
  indexInfo: SqliteIndexInfoPtr,
  iCons: number,
  ppVal: WasmPtr,
) => SqliteResultCode;
```

Defined in: [packages/sqlite-wasm/src/CApi.ts:3146](https://github.com/evoluhq/evolu/blob/bc4578a260dd15d5bbf94b83765ca05984d194cb/packages/sqlite-wasm/src/CApi.ts#L3146)

Writes the right-hand value of constraint iCons to ppVal and returns
SQLITE_OK, or writes NULL and returns SQLITE_NOTFOUND when it is not known,
which is usual unless it is a literal. Only xBestIndex may call it, and the
value is freed when xBestIndex returns.

Wasm type `i(iii)`. Signature `["sqlite3_vtab_rhs_value", "int",
"sqlite3_index_info*", "int", "**"]` from SQLite's table.

See https://sqlite.org/c3ref/vtab_rhs_value.html.