Re: Not null constraint in postgre

From: Chamath Sajeewa <csgsajeewa(at)gmail(dot)com>
To: "Amit S(dot)" <comeonamit(at)gmail(dot)com>
Cc: pgsql-novice(at)lists(dot)postgresql(dot)org
Subject: Re: Not null constraint in postgre
Date: 2020-07-27 06:00:47
Message-ID: CACpofehznhV06NfCWpk_gMUqcy4szvPfFKagCxVa3=cGMxCqdQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hi,
column data type is int4.
Thanks!

On Mon, 27 Jul 2020, 11:19 Amit S., <comeonamit(at)gmail(dot)com> wrote:

> Hi Chamath,
>
> Here is an article explaining the same:::
>
>
> https://www.enterprisedb.com/postgres-tutorials/how-null-and-empty-strings-are-treated-postgresql-vs-oracle
>
> Thanks, Amit
>
> On Mon, Jul 27, 2020 at 11:15 AM Chamath Sajeewa <csgsajeewa(at)gmail(dot)com>
> wrote:
>
>> Hi,
>> There is a column in my table with not null constraint. Default value is
>> set to 0 for that column. In my query, column value is set to null. When i
>> try to execute that query in pgsql, it is getting failed due to constraint
>> violation. Any idea? This is working in oracle.
>> Thank You!
>>
>
>
> --
>
> Amit Sharma
>

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Didier Gasser-Morlay 2020-07-27 06:01:32 Re: Not null constraint in postgre
Previous Message Amit S. 2020-07-27 05:49:47 Re: Not null constraint in postgre