Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Update table problem
The problem in in the first select clause referencing the bcc.bccuser
bcc.
You probably need to write all of the conditions in the second select
clause into the first clause to ensure that the bcc.address1 is not
null.
Mike Krolewski
Anker Møller wrote:
> When I run the following update
>
> UPDATE xal_supervisor.debtable xal
> SET xal.address1 =
> (SELECT REPLACE(RTRIM(SUBSTR(bcc.address1, 0, 30)),'*',' ')
> FROM bcc.bccuser bcc
> WHERE bcc.public_id = xal.accountnumber)
> WHERE xal.accountnumber IN
> (SELECT bcc.public_id
> FROM bcc.bccuser bcc
> WHERE bcc.address1 IS NOT NULL AND
> bcc.address1 <> '' AND
> xal.address1 = '' AND
> bcc.public_id = xal.accountnumber);
>
> I get the error
>
> FROM bcc.bccuser bcc
> *
> ERROR at line 6:
> ORA-01407: cannot update mandatory (NOT NULL) column to NULL
>
> But why? - I only selects NOT NULL colums in my where clause
Received on Tue Apr 14 1998 - 02:16:07 CDT
![]() |
![]() |