public inbox for [email protected]  
help / color / mirror / Atom feed
From: Tom Lane <[email protected]>
To: Jian He <[email protected]>
Cc: pgsql-sql <[email protected]>
Subject: Re: Does postgresql know the check condition is valid or not. or can check deduce from multiple conditions
Date: Wed, 06 Apr 2022 00:10:25 -0400
Message-ID: <[email protected]> (raw)
In-Reply-To: <CAMV54g2OxGKMyuUVwNM0LdDZsvM7XJVbe4WmVRMLNTZ5X1d0Gg@mail.gmail.com>
References: <CAMV54g2OxGKMyuUVwNM0LdDZsvM7XJVbe4WmVRMLNTZ5X1d0Gg@mail.gmail.com>

Jian He <[email protected]> writes:
> CREATE TABLE emp (test_check int check ( test_check >1 and test_check
> < 0 ));

> Even with the above mentioned step, does postgresql know above check
> constraint condition always false.

No, not explicitly.  If the constraint always fails, that is
your problem not Postgres'.

			regards, tom lane





view thread (3+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected]
  Subject: Re: Does postgresql know the check condition is valid or not. or can check deduce from multiple conditions
  In-Reply-To: <[email protected]>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox