>No, what I mean is this
>
>Orders
>OrderDetail
>
>
>Update O set OrderQty = OD.Qty
>from Orders O
>inner join OrderDetail OD
>on O.OrderID = OD.OrderID
>
>In this case one Order has multiple OrderDetails records. Using the update I showed (perfect syntax), we don't know what we will end up with since one record in Order table corresponds to multiple records in the OrderDetails.
>
>If in your update you can guarantee, that each record you're updating has one (or 0) corresponding records in the other table, then you should be OK.
Ok, yes, for that part I agree that a one to many relationship could cause disastrous updates. I will double check that. But, I think what was sent to me was querying into a single record for the relationship.
What I was mostly concentrated about was the Update clause, the first line. Your syntax is also using the alias but avoids using it in the Set clause. I guess it can be omitted at that level as there is no confusion on which table the update will be done.