Re: Error in update query

Tech-Archive recommends: Speed Up your PC by fixing your registry



Try:
UPDATE T_CC_comune
SET T_CC_comune.Causale = "STIPENDIO GLORIA",
T_CC_comune.[Centro Costo] = "stipendio gloria"
WHERE ...

It's acutally the UPDATE clause, but the table you are updating must be shown once only (even though you are updating 2 fields.)

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"morgan" <morgan@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:6CC8336C-E08B-46EE-ACF7-4F3E99F17CD7@xxxxxxxxxxxxxxxx
Hi everyone,
I have the following query to update a table but it returns an error that
sounds something like that: <It's not possible to repete the name of table
"T_CC_comune" in the FROM clause>. (My Access version is in Italian)
What is wrong?

UPDATE T_CC_comune, T_CC_comune SET T_CC_comune.Causale = "STIPENDIO
GLORIA", T_CC_comune.[Centro Costo] = "stipendio gloria"
WHERE (((T_CC_comune.Causale) Like "*stipendio*") AND
((T_CC_comune.Descrizione) Like "*gloria*") AND ((T_CC_comune.[Data
Operazione]) Between Date() And DateAdd("m",-2,Date())));

.