Hi,
I am using MySql Ver ll.15 distrib. 3.23.41
I want to write an sql query something like:
update ddata
set ddata.pubkey = pubdata.pubkey,
ddata.title=pubdata.title
where ddata.dkey=pubdata.dkey;
This generates an error:
ERROR 1109: Unknown table 'pubdata' in where clause
and using thi
Hi,
I am sure this is an old chestnut, but a web search has revealed no answers.
I have:
table pubdata (
dkey smallint(5) unsigned NOT NULL default '0',
pubkey smallint(5) unsigned NOT NULL default '0',
title varchar(100) NOT NULL default '' )";
table ddata (
dkey smallint(5) unsigned NOT NULL
Hi,
I am sure this is an old chestnut, but a web search has revealed no answers.
I have:
table pubdata (
dkey smallint(5) unsigned NOT NULL default '0',
pubkey smallint(5) unsigned NOT NULL default '0',
title varchar(100) NOT NULL default '' )";
table ddata (
dkey smallint(5) unsigned NOT NULL
Hi!
I just happend to notice this old email...
> "Moshe" == Moshe Gurvich <[EMAIL PROTECTED]> writes:
Moshe> In MySQL 3.23, how to update one table using information from another table.
Moshe> update table1 set value1=t2.value2
Moshe> from table1 as t inner join table2 as t1 using(pk_key)
On Fri, 2001-11-02 at 09:57, Paul DuBois wrote:
> At 9:47 AM -0700 11/2/01, Steve Meyers wrote:
> >That's a dangerous solution. If there are more columns in test2 than ID
> >and Value, the REPLACE will delete those values. As you noted in the
> >manual, the old record is deleted before the new r
At 9:47 AM -0700 11/2/01, Steve Meyers wrote:
>That's a dangerous solution. If there are more columns in test2 than ID
>and Value, the REPLACE will delete those values. As you noted in the
>manual, the old record is deleted before the new record is inserted.
>
>Multi-table updates should happen
That's a dangerous solution. If there are more columns in test2 than ID
and Value, the REPLACE will delete those values. As you noted in the
manual, the old record is deleted before the new record is inserted.
Multi-table updates should happen in 4.1, I think, which is due out
fairly soon.
If
AM
To: [EMAIL PROTECTED]
Subject: UPDATE table1 FROM table2
In MySQL 3.23, how to update one table using information from another table.
update table1 set value1=t2.value2
from table1 as t inner join table2 as t1 using(pk_key) ???
or
update table1 as t1 inner join table2 as t2 using(pk_key)
In MySQL 3.23, how to update one table using information from another table.
update table1 set value1=t2.value2
from table1 as t inner join table2 as t1 using(pk_key) ???
or
update table1 as t1 inner join table2 as t2 using(pk_key)
set t1.value1=t2.value2 ???
Is it possible at all?
Thank you