RE: Are these suppose to be equivalent?

  • From: Stephen.Lee@xxxxxxxx
  • To: jkstill@xxxxxxxxx
  • Date: Tue, 28 Sep 2004 11:36:04 -0500

I think there is a 1:1 relation.  On the surface, based on what I know about
SQL, it would seem that if the subquery returns one value, then all columns
of planb_location would be set to that value; if the subquery returns
multiple values, the result should be an error(??).  But there is no error.
It works, and the updates correspond correctly.  So clearly, Oracle is
keeping the rows that match up "inside" the subquery properly matched up
"outside" the subquery.  And now we are back to the whole issue of whether
there is an official inside and outside of the subquery.  That is: Is the
update with the subquery SUPPOSED to work, or does it just happen to work
because of some subquery magic applied by Oracle.

>-----Original Message-----
>It would appear that statement #2 should update a subset of the data
>that statement #1 is updating.
>
>One exception would be if there is a 1:1 relation between location
>and planb_location.
--
//www.freelists.org/webpage/oracle-l

Other related posts: