G
Guest
I am getting syntax error for the following update statement
update post set a.edate=b.edate from
post as a, temp as b where a.id=b.id and a.edate='20011231'
I get syntax error after b.edate.
Here is what I intend doing -
There are two tables post and temp both with id as part of key.
I want to update table post with date from table temp only for the record in
post where id matches id in table temp and the edate = '20011231' and not any
other record with the same id.
eg. post data is
id edate
1 1/1/1991
1 2/1/1992
1 12/31/2001
2 3/15/1990
2 12/31/2001
temp data is
1 2/1/2001
2 1/12/1999
Can someone help me in fixing this problem.
Thank you for your help in advance!
-Me
update post set a.edate=b.edate from
post as a, temp as b where a.id=b.id and a.edate='20011231'
I get syntax error after b.edate.
Here is what I intend doing -
There are two tables post and temp both with id as part of key.
I want to update table post with date from table temp only for the record in
post where id matches id in table temp and the edate = '20011231' and not any
other record with the same id.
eg. post data is
id edate
1 1/1/1991
1 2/1/1992
1 12/31/2001
2 3/15/1990
2 12/31/2001
temp data is
1 2/1/2001
2 1/12/1999
Can someone help me in fixing this problem.
Thank you for your help in advance!
-Me