go-sql-driver/mysql

Implement cursor support

Open

#1.053 geöffnet am 7. Jan. 2020

Auf GitHub ansehen
 (4 Kommentare) (7 Reaktionen) (0 zugewiesene Personen)Go (1.789 Forks)batch import
database/sql issueenhancementhelp wanted

Repository-Metriken

Stars
 (9.946 Stars)
PR-Merge-Metriken
 (Durchschn. Merge 5h 59m) (4 gemergte PRs in 30 T)

Beschreibung

Issue description

In some cases it might be undesirable to fetch a potentially huge resultset at once.

MySQL provides cursors for that in the binary protocol (prepared statements).

First, a cursor flag has to be set in COM_STMT_EXECUTE, then the result chunks can be requested with the COM_STMT_FETCH command.

Initially, we will probably only support forward-only and read-only cursors. However the question remains, trough what interface we make this feature available.

Contributor Guide