UPDATE testing JOIN sell_registry ON testing.client_code = sell_registry.client_code SET testing.sell_date = sell_registry.sell_date;
INSERT INTO testing( client_code, sell_date ) SELECT client_code, sell_date FROM sell_registry ON DUPLICATE KEU UPDATE testing.sell_date = sell_registry.sell_date
UPDATE testing JOIN sell_registry ON testing.client_code = sell_registry.client_code SET testing.sell_date = sell_registry.sell_date; INSERT INTO testing( client_code, sell_date ) SELECT client_code, sell_date FROM sell_registry WHERE NOT EXISTS( SELECT 1 FROM testing WHERE testing.client_code = sell_registry.client_code );
| Subject | Written By | Posted |
|---|---|---|
| inserting + sorting | Mateus Almeida da Silva | 03/29/2012 09:46AM |
| Re: inserting + sorting | laptop alias | 03/29/2012 04:08PM |
| Re: inserting + sorting | Mateus Almeida da Silva | 03/30/2012 06:08AM |
| Re: inserting + sorting | irek kordirko | 03/29/2012 04:10PM |
| Re: inserting + sorting | Mateus Almeida da Silva | 03/30/2012 05:44AM |
Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.