Skip to content

feat(pdo): add next-rowset statement wrapper#31

Merged
Chemaclass merged 1 commit into
mainfrom
feat/17-next-rowset
Jun 3, 2026
Merged

feat(pdo): add next-rowset statement wrapper#31
Chemaclass merged 1 commit into
mainfrom
feat/17-next-rowset

Conversation

@Chemaclass

Copy link
Copy Markdown
Member

Wraps PDOStatement::nextRowset as pdo/next-rowset. Returns the boolean PDO result (true if it advanced to another rowset, false when none remain) - matching the connection-level begin/commit/rollback precedent of returning ^bool rather than the struct, since the boolean is the meaningful signal here.

Note on the test driver

Multi-rowset statements come from stored procedures (MySQL/Postgres). SQLite (the test driver) doesn't support them: nextRowset raises IM001. The test next-rowset-rejected-on-sqlite therefore accepts either false or a \PDOException, proving the call reaches nextRowset. The wrapper is fully functional on drivers that return multiple rowsets.

  • Removed from the "Not implemented yet" block in src/pdo/statement.phel.
  • README API table + CHANGELOG ## [Unreleased] updated.

Polish pass: no refactor needed - one-liner consistent with the other ^bool mutators.

composer test green (50 assertions).

Closes #17

@Chemaclass Chemaclass added the enhancement New feature or request label Jun 3, 2026
@Chemaclass Chemaclass self-assigned this Jun 3, 2026
@Chemaclass Chemaclass merged commit 67e785a into main Jun 3, 2026
1 check passed
@Chemaclass Chemaclass deleted the feat/17-next-rowset branch June 3, 2026 05:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement statement/next-rowset wrapper for PDOStatement::nextRowset

1 participant