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

SQLITE_ERROR: no such column #143

Open
cdiaz opened this issue May 18, 2017 · 0 comments
Open

SQLITE_ERROR: no such column #143

cdiaz opened this issue May 18, 2017 · 0 comments

Comments

@cdiaz
Copy link

cdiaz commented May 18, 2017

When use findById() and pass a uuid alphanumeric string, example:

User.findById(6f13eba03b6d11e780d5c59d28f4b039, function(err, user){
   // your code here
})

show:
Unhandled rejection Error: SQLITE_ERROR: no such column: "6f13eba03b6d11e780d5c59d28f4b039"

this is my model:

const User = schema.define('user', {
    id: { type: schema.String, unique : true },
    username: { type: schema.String, limit: 25 },
    email: { type: schema.String, limit: 100, unique : true },
    password: { type: schema.String },
    role: { type: schema.String }
}, {
    primaryKeys: ["id"]
});

This works fine but only allows integer, non-alphanumeric characters
I have also tested with the mysql adapter and the same thing happens

@cdiaz cdiaz changed the title Sqlite3 adapter: unrecognized token SQLITE_ERROR: no such column May 18, 2017
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