go-sql-driver/mysql

Implement cursor support

Open

#1053 aperta il 7 gen 2020

Vedi su GitHub
 (4 commenti) (7 reazioni) (0 assegnatari)Go (1789 fork)batch import
database/sql issueenhancementhelp wanted

Metriche repository

Star
 (9946 star)
Metriche merge PR
 (Merge medio 5h 59m) (4 PR mergiate in 30 g)

Descrizione

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.

Guida contributor