Line 344:
Line 344:
MySQL Syntax:
MySQL Syntax:
<syntaxhighlight lang="sql">
<syntaxhighlight lang="sql">
−
UPDATE table_taget as target, table_source as source SET fieldtarget=source.fieldsource
+
UPDATE table_target as target, table_source as source SET fieldtarget=source.fieldsource
WHERE source.rowid=target.rowid;
WHERE source.rowid=target.rowid;
</syntaxhighlight>
</syntaxhighlight>
Line 350:
Line 350:
PgSQL Syntax:
PgSQL Syntax:
<syntaxhighlight lang="sql">
<syntaxhighlight lang="sql">
−
UPDATE table_taget as target SET fieldtarget=source.fieldsource
+
UPDATE table_target as target SET fieldtarget=source.fieldsource
FROM table_source as source WHERE source.rowid=target.rowid;
FROM table_source as source WHERE source.rowid=target.rowid;
</syntaxhighlight>
</syntaxhighlight>
Line 357:
Line 357:
<syntaxhighlight lang="php">
<syntaxhighlight lang="php">
if ($this->db->type=='pgsql') {
if ($this->db->type=='pgsql') {
−
$sql="UPDATE table_taget as target SET fieldtarget=source.fieldsource
+
$sql="UPDATE table_target as target SET fieldtarget=source.fieldsource
FROM table_source as source WHERE source.rowid=target.rowid";
FROM table_source as source WHERE source.rowid=target.rowid";
} else {
} else {
−
$sql= "UPDATE table_taget as target, table_source as source SET fieldtarget=source.fieldsource
+
$sql= "UPDATE table_target as target, table_source as source SET fieldtarget=source.fieldsource
WHERE source.rowid=target.rowid";
WHERE source.rowid=target.rowid";
}
}