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

Where can be called on select directly #170

Closed
AuspeXeu opened this issue Nov 19, 2020 · 1 comment
Closed

Where can be called on select directly #170

AuspeXeu opened this issue Nov 19, 2020 · 1 comment

Comments

@AuspeXeu
Copy link
Contributor

The following code will compile without errors.

db.select(db.users.id).where(db.users.id.eq(1)).from(db.users)

but generate the invalid SQL.

SELECT users.id WHERE users.id = $1 FROM users

Leaving the user with.

error: syntax error at or near "FROM"

@martijndeh
Copy link
Contributor

This is correct. Mammoth doesn't fully ensure the SQL you type is also correct—yet. See #128. This is actually considered a good first issue to pick up for developers new to the codebase.

I'm closing this in favour of the already open issue. Thanks for the report!

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

2 participants