Fix check for name of first column #8
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I could not edit a simple SQLite database using
sqlite-mode-extras-edit-row-fieldbecause it would only print "First column must be id" (similar to #5).As far as I understand the code, this check should make sure that the value from the first column is actually an id before updating the row.
sqlite-mode-extras-edit-row-fieldthen proceeds to use this first-column value to select the row to update via therowid(... WHERE rowid = ?).So shouldn't the check then be about
rowidinstead ofid? Additionally, according to https://github.com/emacs-mirror/emacs/blob/master/lisp/sqlite-mode.el#L174,rowid(and notid, which might not even exist) will actually always be the first column in the list of data.When I modify the code as such, field-editing is working for me, so I guess this fixes #5.