By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,444 Members | 3,182 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,444 IT Pros & Developers. It's quick & easy.

Update query using Subquery Not working

P: n/a

Hi all,

I have the following query in Visual Foxpro that is throwing error.

UPDATE T1 set T1.C2 = (select T2.C2 from T2 where T1.c1 = T2.C1)

I tried several methods for updating the value of the another column.
It is not working. Can any one has any idea for using the subquery in
the Update statement?
--
Posted via http://dbforums.com
Nov 12 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
sivaram <me*********@dbforums.com> wrote in message news:<33****************@dbforums.com>...
Hi all,

I have the following query in Visual Foxpro that is throwing error.

UPDATE T1 set T1.C2 = (select T2.C2 from T2 where T1.c1 = T2.C1)

I tried several methods for updating the value of the another column.
It is not working. Can any one has any idea for using the subquery in
the Update statement?


if the subquery can return more than one value (if T1--(1,M)--T2)
then, this makes sense. How could you update a single record to
several records?
Nov 12 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.