MCPcopy Create free account
hub / github.com/WiseLibs/better-sqlite3 / rows

Function rows

test/34.database.table.js:99–103  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

97 this.db.table('vtab', {
98 columns: ['a', 'b', 'c', 'd', 'e'],
99 *rows() {
100 for (const obj of rows) {
101 yield Object.values(obj);
102 }
103 },
104 });
105 expect(this.db.prepare('SELECT * FROM vtab').all()).to.deep.equal(rows);
106 expect(this.db.prepare('SELECT * FROM vtab WHERE b < 500').all()).to.deep.equal(rows.slice(0, 1));

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected