See my answer below for MWE!
I know this sounds silly and the answer is probably right in front of me, but I can't understand why I am getting this SQLITE_RANGE error, because my object looks like it has all the necessary properties.
console.log "values " , values # Recording in db console.assert values.login? console.assert values.password_sha? console.assert values.email? console.assert values.token? values.password = null @db.run "INSERT INTO user VALUES (NULL, $login, $password_sha, $email, $token)", values, (err) -> console.error err if err?
Here is the output of my server
values { login: 'ostream', email: 'ijw', password: 'justine', token: 'acppn99ngiafw29', password_sha: 'b1820c2ec34175954bdaa42038b48886b4c83f8d53f88b5315c415898855e4f8' } { [Error: SQLITE_RANGE: bind or column index out of range] errno: 25, code: 'SQLITE_RANGE' }
Thanks in advance!
source share