Skip to content
New issue

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

rows.go Scan() crashes if no arguments #2

Open
khanzf opened this issue Sep 30, 2021 · 0 comments
Open

rows.go Scan() crashes if no arguments #2

khanzf opened this issue Sep 30, 2021 · 0 comments

Comments

@khanzf
Copy link
Contributor

khanzf commented Sep 30, 2021

If the SELECT of a query does not contain any arguments, such as
SELECT FROM table WHERE ....
then the Scan() function crashes on what is currently line 69:
for i, col := range r.rows[r.pos-1] {
I suspect this is because r.pos is 0, so minus 1 is -1, which results in an index error.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant