We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When I do a QueryRow() query, the Scan() panics with this error:
QueryRow()
Scan()
index out of range [-1]
This seem to be related to this line 72:
for i, col := range r.rows[r.pos-1] {
where r.pos is 0.
r.pos
0
The text was updated successfully, but these errors were encountered:
you need to add Next() call
this is a simple example
columns := []string{"id"} pgxRows := pgxpoolmock.NewRows(columns).AddRow(100).ToPgxRows() pgxRows.Next() suite.mockPool.EXPECT().QueryRow(gomock.Any(), ` INSERT INTO "users"("login", "password") VALUES ($1, $2) returning "@users"`, user.Login, user.Password).Return(pgxRows)
Sorry, something went wrong.
No branches or pull requests
When I do a
QueryRow()
query, theScan()
panics with this error:This seem to be related to this line 72:
where
r.pos
is0
.The text was updated successfully, but these errors were encountered: