We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
CHECK
Having a schema with defined constraint checks, I'd like to see a meaningful error message.
.check(Expr::col(Products::Price).gt(0))
Without it, all we'll get is:
⛔️ new row for relation "products" violates check constraint "products_check".
Extend the API in a way it could introduce names for constraints.
CREATE TABLE products ( product_no integer, name text, price numeric CONSTRAINT positive_price CHECK (price > 0) -- ^^^^^^^^^^^^^^ );
Matching error messages against those "positive_price" names allows translating them for end users.
"positive_price"
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Motivation
Having a schema with defined constraint checks, I'd like to see a meaningful error message.
Without it, all we'll get is:
Proposed Solutions
Extend the API in a way it could introduce names for constraints.
Matching error messages against those
"positive_price"
names allows translating them for end users.The text was updated successfully, but these errors were encountered: