db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kamesh Parameswaran <kapar...@cisco.com>
Subject RE: SQL Syntax issue
Date Fri, 07 Aug 2009 12:55:52 GMT
If the below mentioned example is your use case, you can try what Segel
suggested.
 
~Kamesh

  _____  

From: Michael Segel [mailto:msegel@segel.com] On Behalf Of derby@segel.com
Sent: Friday, August 07, 2009 6:05 PM
To: 'Derby Discussion'
Subject: RE: SQL Syntax issue



Why do you need two tables in your update?

 

Its not really a nested query but an Update statement where you use a select
statement to help qualify the Update.

 

See the standard SQL syntax on this.

 

  _____  

From: Ravinder Reddy [mailto:ravinder.pandiri@gmail.com] 
Sent: Friday, August 07, 2009 7:06 AM
To: Derby Discussion
Subject: Re: SQL Syntax issue

 

Hi,

 

I think , you can't do that.

Instead use nested queries (I am not sure Derby supports nested queries
though).

 

 

On Fri, Aug 7, 2009 at 5:07 PM, Priyanka Karnawat
<priyanka@sungraceinfotech.co.in> wrote:

Can we use 2 or more tables in UPDATE clause?
eg. UPDATE T1, T2
SET T1.name = 'abc'
WHERE T1.id = T2.id




-- 
Ravinder Reddy


Mime
View raw message